Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

test failure on arch linux #1410

Open
skwerlman opened this issue Oct 20, 2020 · 2 comments
Open

test failure on arch linux #1410

skwerlman opened this issue Oct 20, 2020 · 2 comments

Comments

@skwerlman
Copy link

Bug report

Describe the bug
One test fails when run on liniux

To Reproduce
Steps to reproduce the behavior:

  1. download and extract the sources for the latest release (beta 24 in this case)
  2. run dotnet test in that directory
  3. See the following error:
Test run for /home/sk/pkg/embystat_pkg/src/EmbyStat-0.2.0-beta.24/Tests.Unit/bin/Debug/netcoreapp3.1/Tests.Unit.dll(.NETCoreApp,Version=v3.1)
Microsoft (R) Test Execution Command Line Tool Version 16.3.0-dev+55e7e45431c9c05656c999b902686e7402664573
Copyright (c) Microsoft Corporation.  All rights reserved.

Starting test execution, please wait...

A total of 1 test files matched the specified pattern.

[xUnit.net 00:00:05.86]     Tests.Unit.Services.LogServiceTests.GetAnonymousLogStream_Should_Return_Log [FAIL]

X Tests.Unit.Services.LogServiceTests.GetAnonymousLogStream_Should_Return_Log [317ms]
  Error Message:
   Expected lines to be 
"Log line: http://xxx.xxx.xxx.xxx:xxxx; ApiKey:xxxxxxxxxxxxxx; wss://xxx.xxx.xxx.xxx:xxxx; serverId:xxxxxxxxxxxxxx
" with a length of 115, but 
"Log line: http://xxx.xxx.xxx.xxx:xxxx; ApiKey:xxxxxxxxxxxxxx; wss://xxx.xxx.xxx.xxx:xxxx; serverId:xxxxxxxxxxxxxx
" has a length of 114, differs near "
" (index 113).
  Stack Trace:
     at FluentAssertions.Execution.XUnit2TestFramework.Throw(String message)
   at FluentAssertions.Execution.TestFrameworkProvider.Throw(String message)
   at FluentAssertions.Execution.DefaultAssertionStrategy.HandleFailure(String message)
   at FluentAssertions.Execution.AssertionScope.FailWith(Func`1 failReasonFunc)
   at FluentAssertions.Execution.AssertionScope.FailWith(Func`1 failReasonFunc)
   at FluentAssertions.Primitives.StringEqualityValidator.ValidateAgainstLengthDifferences()
   at FluentAssertions.Primitives.StringValidator.Validate()
   at FluentAssertions.Primitives.StringAssertions.Be(String expected, String because, Object[] becauseArgs)
   at Tests.Unit.Services.LogServiceTests.GetAnonymousLogStream_Should_Return_Log() in /home/sk/pkg/embystat_pkg/src/EmbyStat-0.2.0-beta.24/Tests.Unit/Services/LogServiceTests.cs:line 147

Test Run Failed.
Total tests: 462
     Passed: 461
     Failed: 1
 Total time: 14.8769 Seconds

Expected behavior
All tests should pass

Screenshots
N/A

System (please complete the following information):

  • OS: Arch Linux
  • Browser: N/A
  • Version: 0.2.0-beta.24
  • Media server type: N/A

Additional context
I am writing a PKGBUILD with the intent of adding it to the AUR. Having the tests pass is needed to implement the recommended check function: https://wiki.archlinux.org/index.php/creating_packages#check()

@mregni
Copy link
Owner

mregni commented Nov 6, 2020

Thanks for taking the time to create a PKGBUILD for it! Strange that this test is failing because it doesn't fail on my systems.
Seems to me that the output strings are identical with a length of 115. I can have a look why this is failing. Maybe some weird stuff is happening when moving from a windows system to a unix system?

@skwerlman
Copy link
Author

skwerlman commented Nov 7, 2020

my guess is it expects a CRLF line ending (default for windows) but its only getting LF (default on linux)
thisd explain why the differs near bit is split over 2 lines

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants