Skip to content
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

Emit errors for collection assignments #3456

Merged
merged 2 commits into from
Oct 4, 2023
Merged

Conversation

nirinchev
Copy link
Member

@nirinchev nirinchev commented Oct 3, 2023

Description

Fixes #3455

TODO

  • Changelog entry
  • Tests (if applicable)

@coveralls-official
Copy link

coveralls-official bot commented Oct 3, 2023

Pull Request Test Coverage Report for Build 6407334697

  • 0 of 0 changed or added relevant lines in 0 files are covered.
  • No unchanged relevant lines lost coverage.
  • Overall coverage remained the same at 80.262%

Totals Coverage Status
Change from base Build 6381595711: 0.0%
Covered Lines: 6318
Relevant Lines: 7762

💛 - Coveralls

[TestCase("IgnoreObjectNullabilityClass")]
[TestCase("UnsupportedBacklink", "UnsupportedBacklink", "BacklinkObj")]
public async Task ErrorComparisonTest(string filename, params string[] classNames)
public static object[][] ErrorTestCases = Directory.GetFiles(_errorClassesPath)
Copy link
Contributor

Choose a reason for hiding this comment

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

I understand the sentiment, but you have to admit it's kinda ugly 😁

Copy link
Member Author

Choose a reason for hiding this comment

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

Agree, but we clearly forget to add test cases there - the CollectionError tests were missing and I was wondering for quite some time why nothing is failing when I changed my code 😅

Copy link
Member Author

Choose a reason for hiding this comment

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

I reworked the test discovery - let me know if now it's prettier 😜

Copy link
Contributor

Choose a reason for hiding this comment

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

Regexes ftw it seems! It looks better I think ;)

Copy link
Contributor

@papafe papafe left a comment

Choose a reason for hiding this comment

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

Looks good!

@nirinchev nirinchev merged commit 66ffd6f into main Oct 4, 2023
64 of 65 checks passed
@nirinchev nirinchev deleted the ni/sg-collection-assignment branch October 4, 2023 16:01
nirinchev added a commit that referenced this pull request Nov 1, 2023
* main:
  Small fixes to source generator (#3466)
  Make websocket error logging exceptionally verbose (#3459)
  Emit errors for collection assignments (#3456)
  Fix docfx source files (#3453)
  Fix typo (#3454)
  Add User.Changed event (#3433)
  Allow customizing json ignore attribute for serialized classes (#3451)
  Update README.md (#3450)
  Fix changelog
  Prepare for vNext (#3444)
  Prepare for 11.5.0 (#3442)
@github-actions github-actions bot locked as resolved and limited conversation to collaborators Mar 11, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Emit errors in case a collection property is initialized
2 participants