1
0
mirror of https://github.com/chylex/.NET-Community-Toolkit.git synced 2024-11-25 01:42:46 +01:00
Commit Graph

1968 Commits

Author SHA1 Message Date
Sergio Pedri
eab4b9ed28 More whitespaces and code style tweaks 2021-11-02 00:28:30 +01:00
Sergio Pedri
a1db2247fc Fix failing unit tests 2021-11-02 00:11:58 +01:00
Sergio Pedri
93cb82a0d0 Fix incorrect whitespaces, minor code style tweaks 2021-11-02 00:01:05 +01:00
Sergio Pedri
6afdd81742 Refactor multiline variable declarations 2021-11-01 23:42:45 +01:00
Sergio Pedri
51c7a67c20 More code style improvements and tweaks
- Remove unused namespaces
- Remove unused attributes
- Remove unnecessary #nullable enable directives
- Sort using directives
- Simplify names
2021-11-01 22:29:46 +01:00
Sergio Pedri
9f4c9fad7f Remove unnecessary using directives 2021-11-01 22:14:16 +01:00
Sergio Pedri
58c0dd96c4 Fix namespaces in unit test projects 2021-11-01 22:12:56 +01:00
Sergio Pedri
c176080d37 Switch whole solution to file-scoped namespaces 2021-11-01 20:46:46 +01:00
Sergio Pedri
32f3f7ce3c Hide imported files in projects from .targets file 2021-11-01 20:34:17 +01:00
Sergio Pedri
7a2295b03c Update some code style rules
In particular:
- Use explicit types everywhere to improve clarity
- Use target-typed new() expression when target is explicit
- Use explicit discard for value-returning statements
2021-11-01 20:34:00 +01:00
Sergio Pedri
11ab330e69 Enable nullability annotations in the entire solution 2021-11-01 19:27:55 +01:00
Sergio Pedri
25879bbaa4 Update NuGet packages in the solution 2021-11-01 19:01:04 +01:00
Sergio Pedri
768a9d39ed Streamline HighPerformance package project properties 2021-11-01 18:47:15 +01:00
Sergio Pedri
941098338f Remove .NET Core 2.1 targets 2021-11-01 17:48:32 +01:00
Sergio Pedri
20f8ed1a59 Rename packages away from "Windows" name 2021-11-01 17:26:52 +01:00
Sergio Pedri
8b7c87284b Update namespaces from Microsoft.Toolkit to CommunityToolkit 2021-11-01 17:22:05 +01:00
Sergio Pedri
b498321331 Rename folders/projects from Microsoft.Toolkit to CommunityToolkit 2021-11-01 17:07:47 +01:00
Sergio Pedri
fd58931fb0 Rename common .props/.targets files 2021-11-01 16:36:45 +01:00
Sergio Pedri
e6be26c3a2 Better organize solution files in solution explorer 2021-11-01 16:31:57 +01:00
Sergio Pedri
2c999fbe69 Rename unit tests folder 2021-11-01 16:26:47 +01:00
Sergio Pedri
1b66418112 Rename test projects for better consistency 2021-11-01 16:24:24 +01:00
Sergio Pedri
e21ee19af4 Add leftover TaskExtensions tests 2021-11-01 16:10:09 +01:00
Sergio Pedri
624011fbcf Remove FluentAssertions dependency
This aligns all unit testing towards just using MSTest APIs
2021-11-01 16:00:22 +01:00
Sergio Pedri
6373401d3e Refactor Microsoft.Toolkit tests 2021-11-01 13:00:53 +01:00
Sergio Pedri
49e4f15e58 Refactor Mvvm tests 2021-11-01 12:52:51 +01:00
Sergio Pedri
08fdb3d998 Refactor Diagnostics tests 2021-11-01 12:46:06 +01:00
Sergio Pedri
7752669fd6 Rename solution file to work around VS bug
See https://developercommunity.visualstudio.com/t/1568612.
We can consider reverting this once this has been fixed.
Used "dotnet" to be consistent with repo name. Using "NET", "dotNet" or variations would've just been wrong, so "dotnet" seemed like the best alternative.
2021-11-01 12:37:09 +01:00
Sergio Pedri
f1996bb2d4 Remove leftover .targets item 2021-10-31 10:55:08 +01:00
Sergio Pedri
e0edf3e080 Remove HighPerformance.Shared project 2021-10-29 18:15:46 +02:00
Sergio Pedri
de2678f3ec Port and update initial build and solution files 2021-10-29 17:54:22 +02:00
Sergio Pedri
f639d11043 Merge branch 'main' of E:\github\WindowsCommunityToolkit 2021-10-29 17:07:54 +02:00
Sergio Pedri
198008d8e1 Create README.md 2021-10-29 17:06:29 +02:00
Michael Hawker MSFT (XAML Llama)
4dca37073b Merge pull request #4327 from Sergio0694/bugfix/incorrect-notnullorempty-exception
Fixed exception type for Guard.IsNotNullOr[Empty|WhiteSpace]
2021-10-18 10:11:36 -07:00
Sergio Pedri
eebaff831f Fixed exception type for Guard.IsNotNullOr[Empty|WhiteSpace] 2021-10-18 15:53:13 +02:00
Michael Hawker MSFT (XAML Llama)
a053f0b8f2 Merge pull request #4285 from Sergio0694/bugfix/csharp8.0-mvvm-toolkit
Fix MVVM Toolkit build errors when using C# < 9.0
2021-10-07 13:35:32 -07:00
Sergio Pedri
c9c601486f Disabled ValidateAllProperties/RegisterAll generators w/ <= 8.0 2021-09-29 11:30:47 +02:00
Sergio Pedri
7cc3ac6c14 Removed unnecessary C# version checks in two generators 2021-09-29 11:24:29 +02:00
Sergio Pedri
755eb70bdc Fixed nullability warning in ObservableValidator
Also fixed some build warnings in the unit test project
2021-09-28 14:39:46 +02:00
Sergio Pedri
181e63f9a2 Added short path in fallback logic for RegisterAll 2021-09-28 11:08:51 +02:00
Sergio Pedri
9a3462f371 Added short path in fallback logic for ValidateAllProperties 2021-09-28 10:52:54 +02:00
Sergio Pedri
0a090ff802 Added more unit tests for ValidateAllProperties fallback 2021-09-28 10:47:14 +02:00
Michael Hawker MSFT (XAML Llama)
b29ec83d2a Merge pull request #4125 from Nirmal4G/hotfix/warnings
Fix most build warnings from the projects
2021-09-16 12:57:46 -07:00
Rosario Pulella
b833a1300a Merge pull request #4221 from Sergio0694/bugfix/validate-all-generated-props
Fixed ValidateAllProperties generation for generated properties
2021-09-16 14:34:38 -04:00
msftbot[bot]
e3a9464c4b Fixed generated properties within regions (#4227)
<!-- 🚨 Please Do Not skip any instructions and information mentioned below as they are all required and essential to evaluate and test the PR. By fulfilling all the required information you will be able to reduce the volume of questions and most likely help merge the PR faster 🚨 -->

<!-- 👉 It is imperative to resolve ONE ISSUE PER PR and avoid making multiple changes unless the changes interrelate with each other -->

<!-- 📝 Please always keep the "☑️ Allow edits by maintainers" button checked in the Pull Request Template as it increases collaboration with the Toolkit maintainers by permitting commits to your PR branch (only) created from your fork. This can let us quickly make fixes for minor typos or forgotten StyleCop issues during review without needing to wait on you doing extra work. Let us help you help us! 🎉 -->

## Fixes #4225

<!-- Add the relevant issue number after the word "Fixes" mentioned above (for ex: "## Fixes #1234") which will automatically close the issue once the PR is merged. -->

<!-- Add a brief overview here of the feature/bug & fix. -->

## PR Type

What kind of change does this PR introduce?

<!-- Please uncomment one or more options below that apply to this PR. -->

- Bugfix
<!-- - Feature -->
<!-- - Code style update (formatting) -->
<!-- - Refactoring (no functional changes, no api changes) -->
<!-- - Build or CI related changes -->
<!-- - Documentation content changes -->
<!-- - Sample app changes -->
<!-- - Other... Please describe: -->

## What is the current behavior?
Compilation fails If the Microsoft MVVM Toolkit source generator attribute `[ObservableProperty]` is in a `#region` block.
<!-- Please describe the current behavior that you are modifying, or link to a relevant issue. -->

## What is the new behavior?
The generated code is now correct when regions are used.
<!-- Describe how was this issue resolved or changed? -->

## PR Checklist

Please check if your PR fulfills the following requirements: <!-- and remove the ones that are not applicable to the current PR -->

- [X] Tested code with current [supported SDKs](../#supported)
- [X] New component
  - [X] Pull Request has been submitted to the documentation repository [instructions](../blob/main/Contributing.md#docs). Link: <!-- docs PR link -->
  - [X] Added description of major feature to project description for NuGet package (4000 total character limit, so don't push entire description over that)
  - [X] If control, added to Visual Studio Design project
- [X] Sample in sample app has been added / updated (for bug fixes / features)
  - [X] Icon has been created (if new sample) following the [Thumbnail Style Guide and templates](https://github.com/CommunityToolkit/WindowsCommunityToolkit-design-assets)
- [X] New major technical changes in the toolkit have or will be added to the [Wiki](https://github.com/CommunityToolkit/WindowsCommunityToolkit/wiki) e.g. build changes, source generators, testing infrastructure, sample creation changes, etc...
- [X] Tests for the changes have been added (for bug fixes / features) (if applicable)
- [X] Header has been added to all new source files (run _build/UpdateHeaders.bat_)
- [X] Contains **NO** breaking changes
2021-09-16 18:17:45 +00:00
Sergio Pedri
f4fdaf3879 Fixed [AlsoNotifyChangeFor] attribute definition 2021-09-12 20:26:40 +02:00
Nirmal Guru
62134065cd Fix CS8618 warnings
Code CS1591: Non-nullable field must contain a non-null value when exiting constructor.
2021-09-10 07:10:04 +05:30
Nirmal Guru
1293491813 Update UnitTests' EditorConfig
Add comments describing the nature of the warning.
2021-09-10 07:09:39 +05:30
Sergio Pedri
f6d63a7440 Improved unit tests for generated validation methods 2021-09-09 20:12:04 +02:00
Sergio Pedri
56dd350420 Fixed ValidateAllProperties generation for generated properties 2021-09-09 20:12:04 +02:00
Sergio Pedri
0814b3ae63 Added unit tests for new diagnostic 2021-09-08 18:02:11 +02:00