-
Notifications
You must be signed in to change notification settings - Fork 55
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
Refactor the test code #35
Refactor the test code #35
Conversation
{ | ||
public class PropertyTestConverter : TypeConverter | ||
{ | ||
public static event Action<CultureInfo, ITypeDescriptorContext> ConvertFromEventRequiredAssert; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I have not found a better way how it would be possible to pass values for validation
(int) ((ExtensionValueHolder) sp.GetService(typeof(ExtensionValueHolder))).Value; | ||
} | ||
|
||
public class CustomConvertedType |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It looks like this class is not used anywhere
.github/workflows/dotnetcore.yml
Outdated
- name: Test for net47 CecilNetstandardTests | ||
if: matrix.os == 'windows-latest' | ||
run: dotnet test --framework net47 tests/CecilNetstandardTests/CecilNetstandardTests.csproj | ||
- name: Test for net47 CecilTests | ||
if: matrix.os == 'windows-latest' | ||
run: dotnet test --framework net47 tests/CecilTests/CecilTests.csproj | ||
- name: Test for net47 XamlParserTests | ||
if: matrix.os == 'windows-latest' | ||
run: dotnet test --framework net47 tests/XamlParserTests/XamlParserTests.csproj |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Consider checking out the following GitHub Actions setup:
https://github.com/reactiveui/ReactiveUI.Validation/blob/e7bc86ded6f6eeecc781094ad30283bff68fc5fc/.github/workflows/ci-build.yml#L48-L57
E.g. if you build the project first, you can then run unit tests for all built assemblies ending with Tests.csproj
using the *Tests.csproj
glob pattern and the --no-build
option. This will run the tests for both netcoreapp3.1
and net47
as well, just in one command. Could be useful in removing all these if
statements and in generating only one report for all the test projects instead.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Oh, that looks interesting, thanks!
Now by calling |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks @rstm-sf for doing this! The CI configuration looks really good so far.
…dard_tests # Conflicts: # tests/Tests.Common.props
|
@kekekeks hello, does it make sense to update it? |
Hello!
Now that the tests are almost restored (#31), we can try refactoring the test code. This PR suggests doing it:
dotnet test
tests withnetstandard2.0
My primary goal was to try and get rid of the hacks for running tests with VS, but that didn't help
Depends on #31
Closes #33