-
-
Notifications
You must be signed in to change notification settings - Fork 46
Report format with namespace qualifying. #387
-
NOTE: This may be a duplicate - I thought I submitted the question earlier but it hasn't appeared...
I'm trying to get a report that models what the Test Explorer shows: Something like the following:
- Assembly
- Root Namespace1
- Unqualified Test 1
- Unqualified Test 2
- Child Namespace
- Unqualified Test 3
- Unqualified Test 4
- Root Namespace2
- Unqualified Test 5
- Unqualified Test 6
Also, see the example below.
- Root Namespace1
It doesn't appear that any of the options will produce such a report.
The pattern I use is to place tests for the types in a given namespace in their own Test namespace. (e.g., Collection classes are placed in the 'CompanyName'.Collections namespace and the associated tests are in 'CompanyName'.Collections.Tests.
This provides a reasonable grouping in the test explorer and I can expand only the nodes of interest. I'd like to achieve the same in the Fine Code Coverage view.
I've tried QualifiedByNamespaceLevel, FullyQualified and UnqualifiedByNamespace but all three appear to produce the same coverage view.
FWIW: I rerun all tests when I switch options to ensure it's not related to partial coverage reporting.
Is there something I'm missing?
I'm running these tests on Microsoft Visual Studio Community 2022 - Version 17.8.5
Beta Was this translation helpful? Give feedback.
All reactions
Replies: 3 comments 1 reply
-
Options
NamespacedClasses - true
NamespaceQualification - QualifiedByNamespaceLevel
In the report group by namespace to the max level
Beta Was this translation helpful? Give feedback.
All reactions
-
Doh! This was the step I missed: In the report group by namespace to the max level
Unfortunately, changing it causes VS to become unresponsive until the level is updated, and this takes more than a minute. Then, once that completes, expanding or collapsing a node blocks the UI again for 1+ minutes.
For the test run I'm viewing, the maximum namespace level is 7, there are 4 assemblies being tested with 499 tests, and the test run takes 1.8 seconds.
In its current state, the feature is not usable.
Repro Steps:
Run Tests
Wait for FCC report processing to complete. (UI is blocked while report processing runs)
Attempt to changing the grouping level
UI blocks
As noted, report processing itself also blocks the UI for the duration of report process.
I'm sure this wasn't occurring prior to the namespace grouping change because I would often switch to the FCC output window to see if report processing had completed for the current test run.
These are the output steps I see when blocking occurs and it occurs consistently:
Fine Code Coverage 1/28/2024 6:26:07 AM: Processing cobertura
Fine Code Coverage 1/28/2024 6:26:07 AM: Processing report
Fine Code Coverage 1/28/2024 6:26:08 AM: ================================== DONE ==================================
Note that Expand All also blocks the UI but I don't know if this new behavior since I don't normally use that action.
Thanks,
Dan.
Beta Was this translation helpful? Give feedback.
All reactions
-
I should have mentioned, I do like the namespace grouping!
Beta Was this translation helpful? Give feedback.
All reactions
-
The report as it currently stands is a hack on the html report generated by ReportGenerator. To add functionality requested MutationObserver was added to this hack.
I will this week or next week replace the html report and instead create a report with WPF controls.
Beta Was this translation helpful? Give feedback.
All reactions
-
👍 1