Commit Graph

9 Commits

Author SHA1 Message Date
Juster Zhu
c6ac019a4e fix: PathPicker's File Filtering Function malfunctions (#786)
* fix: PathPicker's File Filtering Function malfunctions

Regular expression validation for adding parameters; the sample reference content is as follows:

[Name,Pattern] → True
[123,.exe,.pdb] → True
[All] → True
[ImageAll] → True
[11,*.txt] → True
*.123 → False
*.txt → False
.png → False
[*.txt] → False
[.txt] → False
[a] → True
[a,b] → True
[a,b,c] → True
[a,*] → True
[a,.] → True
[*] → False
[.] → False
[a,] → False
[,a] → False
[] → False
[a,b,] → False
[a,,b] → False
[a*b] → False
[a.b] → False

* Add PathPicker regex validation and headless tests

Introduces regex-based validation for the PathPicker FileFilter property, supporting both NETSTANDARD2_0 and NET8_0 with conditional compilation. Adds headless UI tests and supporting test views to verify correct and incorrect filter patterns.

* Refactor PathPicker tests and update accessibility

Moved PathPicker unit tests from HeadlessTest.Ursa to Test.Ursa, removing UI-dependent test files and replacing them with direct unit tests for ParseFileTypes. Updated PathPicker.cs to make ParseFileTypes internal for improved testability and adjusted regex method accessibility. Updated project file to remove references to deleted test files.

* Update HeadlessTest.Ursa.csproj

* Update src/Ursa/Controls/PathPicker/PathPicker.cs

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

---------

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
2025-10-21 23:03:11 +08:00
copilot-swe-agent[bot]
4d5ff8f8c4 Update coverlet.collector to 6.0.4
Co-authored-by: rabbitism <14807942+rabbitism@users.noreply.github.com>
2025-10-12 14:24:21 +00:00
Dong Bin
2a0ee06bf1 Add comprehensive test coverage for many controls (#737)
Co-authored-by: rabbitism <14807942+rabbitism@users.noreply.github.com>
Co-authored-by: Copilot <198982749+Copilot@users.noreply.github.com>
2025-07-30 16:25:13 +08:00
Dong Bin
c97476e1e8 test: WIP fix testing in ubuntu. 2025-02-17 14:55:05 +08:00
Dong Bin
afd5449f5b test: WIP, fix an issue when passing year event. 2025-02-17 03:03:27 +08:00
Dong Bin
051482de57 test:WIP add tests. Change decade context end date. 2025-02-17 01:39:39 +08:00
Dong Bin
d09431a9f5 test: AutoCompleteBox tests. 2024-12-31 18:49:07 +08:00
rabbitism
41a60d47e1 feat: add unit test. 2024-12-26 18:07:56 +08:00
rabbitism
8bd1962b15 feat:
1. fix #427.
2. add headless test for this fix.
2024-10-08 20:58:40 +08:00