Skip to content

Conversation

@Arlodotexe
Copy link
Member

@Arlodotexe Arlodotexe commented Jun 15, 2023

Until recently, tests only checked the diagnostic output of a source generator, not the actual generated code. This changed with CommunityToolkit/Labs-Windows#336 when we added the PaneOption_GeneratesTitleProperty test.

  • This test also needed to check the sample registry, which is generated in the app head instead of the sample project.
  • This resulted in a copy-pasted method that worked well for that test, but not for the new tests.
  • We needed to properly recreate the Head-Sample project reference setup we have in our solution. These changes now enable that.

This PR contains additional improvements extracted from #44.

@Arlodotexe Arlodotexe added the enhancement New feature or request label Jun 15, 2023
@Arlodotexe Arlodotexe self-assigned this Jun 15, 2023
Copy link
Member

@michael-hawker michael-hawker left a comment

Choose a reason for hiding this comment

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

Small request to update to new string literal. Otherwise, seems alright to me so far. @Arlodotexe did you test updating the main repo to this branch and seeing that it builds as expected there with these changes?

Wouldn't mind a quick pass from @Sergio0694 as well as our resident generator expert... 😉

Copy link
Member

@Sergio0694 Sergio0694 left a comment

Choose a reason for hiding this comment

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

Had a look at the generator, changes seem fine to me under the assumption that the generator was already non-incremental for most of its pipeline and generally incredibly expensive, but my understanding is this intended 😆

Arlodotexe and others added 3 commits June 28, 2023 10:42
@michael-hawker
Copy link
Member

@Arlodotexe LGTM, but looks like conflicts with the bast branch now to resolve?

@Arlodotexe
Copy link
Member Author

Arlodotexe commented Jun 29, 2023

@Arlodotexe LGTM, but looks like conflicts with the bast branch now to resolve?

Had a conflict on pull at one point, so this branch contains a merge commit. Rebase has conflicts, but Squash or Merge will work fine. I'd like to be able to revert 102f46a in the future to continue that work, so I'll use a normal merge here.

@Arlodotexe Arlodotexe merged commit b32c389 into main Jun 29, 2023
@delete-merged-branch delete-merged-branch bot deleted the refactor/samplegen/tests branch June 29, 2023 14:37
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement New feature or request

Projects

Status: Done

Development

Successfully merging this pull request may close these issues.

4 participants