Skip to content

Commit 4d50e08

Browse files
committed
Update todo
1 parent c7bee0c commit 4d50e08

File tree

1 file changed

+58
-0
lines changed

1 file changed

+58
-0
lines changed

TODO.md

Lines changed: 58 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,58 @@
1+
- Move all tests to integration tests and test only via front door (Assert)
2+
- Expose Assert(() => x => y) overload method in Sharp class to delegate to included PowerAssert directly
3+
- Review dynamic support - make sure that dynamic = {...} objects are properly formatted
4+
- Custom formatters
5+
- Custom comparisons
6+
7+
----
8+
9+
Dynamic - only implement (general/binary). Need to be tested/extended to work properly with objects/collections/expando
10+
```csharp
11+
dynamic json = JsonSerializer.Deserialize<dynamic>(jsonString);
12+
Console.WriteLine(json.user.name);
13+
```
14+
15+
```csharp
16+
dynamic person = new ExpandoObject();
17+
person.Name = "Yevhen";
18+
person.Age = 42;
19+
Console.WriteLine($"{person.Name} ({person.Age})");
20+
```
21+
22+
----
23+
24+
**External diff viewers** - this is important to implement.
25+
- Need proper research. In pycharm when pytest assert fails it shows nice diff right inside ide using native means.
26+
- It would be cool impl similar for large multiline strings, or maps, etc. Need to think where this could be useful.
27+
28+
----
29+
30+
**Debugging the Rewriter** - not sure what value this will bring and what changes these requires.
31+
To facilitate debugging, the rewrite task will support a diagnostic MSBuild property:
32+
33+
```xml
34+
<PropertyGroup>
35+
<SharpAssertEmitRewriteInfo>true</SharpAssertEmitRewriteInfo>
36+
</PropertyGroup>
37+
```
38+
39+
When enabled, the rewriter will output detailed logs of its analysis and decisions. This is crucial for troubleshooting unexpected rewrite behavior.
40+
41+
----
42+
43+
**Dependencies**
44+
- PowerAssert (current) — is not used anymore as automatic fallback for unsupported features (need to find all references to this fact and update)
45+
- DiffPlex — string & sequence diffs
46+
- Compare‑Net‑Objects — deep object diffs
47+
- Verify.* — external diff tooling
48+
49+
All these packages need to be properly attributed in README.md
50+
51+
----
52+
53+
**Rewriter Robustness & Fallback - pending**
54+
55+
- Wrap rewriter logic in try-catch
56+
- If analysis fails, leave original Assert call
57+
- Add diagnostic logging controlled by MSBuild property - this looks like 4.3
58+
- Test with edge cases and invalid code

0 commit comments

Comments
 (0)