-
Notifications
You must be signed in to change notification settings - Fork 619
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
Add a unit test project #1444
Add a unit test project #1444
Conversation
<XamlControlsResources xmlns="using:Microsoft.UI.Xaml.Controls" /> | ||
<!-- Other merged dictionaries here --> | ||
</ResourceDictionary.MergedDictionaries> | ||
<ResourceDictionary.ThemeDictionaries> |
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.
Are these resources pasted over from WinUI Gallery? If not all resources are required, may be worth it to clean it up.
azure-pipelines.yml
Outdated
displayName: 'List contents of ArtifactStagingDirectory and DefaultWorkingDirectory' | ||
|
||
- task: VSTest@2 | ||
displayName: 'Run Unit Tests' |
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.
Might be worth it to label it as "Run Sample Unit Tests" since these mostly serve as a demonstration rather than an actual test.
I'm wondering if having unit tests also warrants having a |
@@ -13,7 +13,7 @@ | |||
|
|||
namespace AppUIBasics | |||
{ | |||
class IdleSynchronizer | |||
public class IdleSynchronizer |
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.
Is this related to the unit tests?
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.
At one point I was using it from one of the unit tests. I'll leave it as it is.
@@ -0,0 +1,65 @@ | |||
<Project Sdk="Microsoft.NET.Sdk"> |
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.
Do we not need a certificate for the unit types project?
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.
We're not creating an msix so we don't need the cert.
This adds a set of unit tests to WinUIGallery. The initial set of tests are mostly just to serve as a demonstration of how to write tests in MSTest for WinUI. But as new features are added to WinUI we can optionally write them in a more unit-testable way and add new tests here. Unit tests have the advantage of being quicker and more reliable that UI Interaction tests which is where we are getting most of the coverage now. I've also updated the Azure Pipeline job to execute the unit tests as part of the build. This PR updates the version of WinAppSDK from 1.4 to 1.5 Preview1. Once 1.5.0 stable is released we should update to that. --------- Co-authored-by: Keith Mahoney <you@example.com>
This adds a set of unit tests to WinUIGallery.
The initial set of tests are mostly just to serve as a demonstration of how to write tests in MSTest for WinUI. But as new features are added to WinUI we can optionally write them in a more unit-testable way and add new tests here. Unit tests have the advantage of being quicker and more reliable that UI Interaction tests which is where we are getting most of the coverage now.
I've also updated the Azure Pipeline job to execute the unit tests as part of the build.
This PR updates the version of WinAppSDK from 1.4 to 1.5 Preview1. Once 1.5.0 stable is released we should update to that.