-
Notifications
You must be signed in to change notification settings - Fork 4.7k
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
[wasm][debugger] Fix tests broken on 'main' #68054
Conversation
This test broke because it was checking for the number of members on `System.TimeSpan`, and that changed with dotnet#67666 , which added new members like `TotalNanoseconds`. The test shouldn't depend on this number anyway, so remove that. ``` Failed DebuggerTests.MiscTests.InspectLocalsForToStringDescriptions(line: 137, col: 12, method_name: "MethodWithLocalsForToStringTest", call_other: False, invoke_async: False) [758 ms] Error Message: [ts_props] Number of fields don't match, Expected: 12, Actual: 16 Expected: True Actual: False Stack Trace: at DebuggerTests.DebuggerTestBase.CheckProps(JToken actual, Object exp_o, String label, Int32 num_fields) in /_/src/mono/wasm/debugger/DebuggerTestSuite/DebuggerTestBase.cs:line 800 at DebuggerTests.DebuggerTestBase.CompareObjectPropertiesFor(JToken locals, String name, Object o, String label, Int32 num_fields) in /_/src/mono/wasm/debugger/DebuggerTestSuite/DebuggerTestBase.cs:line 908 at DebuggerTests.MiscTests.InspectLocalsForToStringDescriptions(Int32 line, Int32 col, String method_name, Boolean call_other, Boolean invoke_async) in /_/src/mono/wasm/debugger/DebuggerTestSuite/MiscTests.cs:line 559 ```
Tagging subscribers to 'arch-wasm': @lewing Issue DetailsThis test broke because it was checking for the number of members on The test shouldn't depend on this number anyway, so remove that.
|
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.
{ | ||
if (label == null) | ||
label = name; | ||
var props = await GetObjectOnLocals(locals, name); | ||
try | ||
{ | ||
if (o != null) | ||
await CheckProps(props, o, label, num_fields); | ||
await CheckProps(props, o, label, num_fields, skip_num_fields_check); |
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.
you could reflect in the test ;)
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.
I tried that, and it's a little messy. And the number of members being returned will also change soon (to include private ones), so I'll have to stick with this check!
This test broke because it was checking for the number of members on
System.TimeSpan
, and that changed with#67666 , which added new members
like
TotalNanoseconds
.The test shouldn't depend on this number anyway, so remove that.