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

Unit test "Indentify_Windows_Platform" fails on Linux #21

Closed
axunonb opened this issue Oct 6, 2019 · 5 comments
Closed

Unit test "Indentify_Windows_Platform" fails on Linux #21

axunonb opened this issue Oct 6, 2019 · 5 comments

Comments

@axunonb
Copy link
Member

axunonb commented Oct 6, 2019

Originally posted by @thegruffalo in #19 (comment)

@axunonb axunonb changed the title Unit test "Indentify_Windows_Platform" fails on linux Unit test "Indentify_Windows_Platform" fails on Linux Oct 6, 2019
@axunonb
Copy link
Member Author

axunonb commented Oct 6, 2019

Did you mean to make the Indentify_Windows_Platform test conditional - fails on linux.

Actually the test should work also without ExcludePlatform. The intention is to in include the new Platform class in unit tests.

@axunonb
Copy link
Member Author

axunonb commented Oct 9, 2019

@thegruffalo Could you elaborate what exactly fails with the test, please?

@thegruffalo
Copy link

Here is the test output:

---- Test Execution Summary -----

MailMergeLib.Tests.Platform.Indentify_Windows_Platform:
Outcome: Failed
Error Message:
MailMergeLib.UnsupportedPlatformException : Unknown
Stack Trace:
at MailMergeLib.Platform.DeterminePlatform() in /home/thill/tdev/MMLO/MailMergeLib/MailMergeLib/Platform.cs:line 65
at MailMergeLib.Tests.Platform.Indentify_Windows_Platform() in /home/thill/tdev/MMLO/MailMergeLib/MailMergeLib.Tests/Platform.cs:line 24

Total tests: 1. Passed: 0. Failed: 1. Skipped: 0

As an alternative, maybe, something like this would be easier to implement https://docs.microsoft.com/en-us/dotnet/api/system.runtime.interopservices.runtimeinformation.isosplatform?view=netcore-2.2

@axunonb
Copy link
Member Author

axunonb commented Oct 20, 2019

With commit 1b08f36 we're using System.Runtime.InteropServices.OSPlatform to detect the platform. Does the test pass now on Linux?

@axunonb
Copy link
Member Author

axunonb commented Oct 23, 2019

Tests for commit 1b08f36 complete successfully on Ubuntu 18.04 LTS and Windows.

@axunonb axunonb closed this as completed Oct 23, 2019
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