Skip to content

Conversation

@ryzngard
Copy link
Contributor

@ryzngard ryzngard commented May 8, 2025

No description provided.

@ryzngard ryzngard force-pushed the diagnostic_test branch from 5b395a1 to 4a44394 Compare May 8, 2025 21:50
@ryzngard ryzngard marked this pull request as ready for review May 8, 2025 21:50
@ryzngard ryzngard requested a review from a team as a code owner May 8, 2025 21:50
await testAssetWorkspace.cleanupWorkspace();
});

test('CSharp Diagnostics', async () => {
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nit: This is a "CSharp and Razor Diagnostics" test

expect(diagnostics[0].range).toStrictEqual(new vscode.Range(2, 0, 2, 25));
expect(diagnostics[0].source).toBe('Razor');

expect(diagnostics[1].message).toBe("The name 'Message' does not exist in the current context");
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why not validate the C# diagnostic code too? Would confirm we're sending it through correctly etc.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Let me add that. I wasn't sure how to do it because it's a weird definition but I think I can use toStrictEqual and achieve that

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Oh, it's not the same as the Razor one above? That's interesting...

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yea, it's a code + uri

@ryzngard ryzngard enabled auto-merge May 8, 2025 23:14
@ryzngard ryzngard closed this Jun 19, 2025
auto-merge was automatically disabled June 19, 2025 23:53

Pull request was closed

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants