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

Allow declaring decorators on nested child resources #12209

Merged
merged 3 commits into from
Oct 24, 2023

Conversation

miqm
Copy link
Collaborator

@miqm miqm commented Oct 20, 2023

Fixes #10970

Contributing a Pull Request

If you haven't already, read the full contribution guide. The guide may have changed since the last time you read it, so please double-check. Once you are done and ready to submit your PR, run through the relevant checklist below.

Contributing a feature

  • I have opened a new issue for the proposal, or commented on an existing one, and ensured that the Bicep maintainers are good with the design of the feature being implemented
  • I have included "Fixes #{issue_number}" in the PR description, so GitHub can link to the issue and close it when the PR is merged
  • I have appropriate test coverage of my new feature
Microsoft Reviewers: Open in CodeFlow

@miqm miqm requested a review from shenglol October 20, 2023 07:30
@miqm miqm requested a review from shenglol October 20, 2023 18:57
@miqm miqm marked this pull request as ready for review October 20, 2023 18:57
resource sqlDatabase 'databases' = [for db in dbs: {
name: db
location: 'polandcentral'
}]
Copy link
Contributor

Choose a reason for hiding this comment

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

Can we add some negative test cases to ensure other declaration types are blocked?

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

Sure, will do that tomorrow.

Copy link
Collaborator Author

@miqm miqm Oct 21, 2023

Choose a reason for hiding this comment

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

I added negative tests. I also needed to add visiting MissingDeclarationSyntaxes in the TypeAssignmentVisitor to emit appropriate diagnostics

Copy link
Contributor

@shenglol shenglol left a comment

Choose a reason for hiding this comment

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

:shipit:

@miqm miqm changed the title Unblock declaring decorators on nested child resources Allow declaring decorators on nested child resources Oct 21, 2023
@shenglol shenglol merged commit aeef173 into Azure:main Oct 24, 2023
40 checks passed
@github-actions
Copy link
Contributor

Test this change out locally with the following install scripts (Action run 6631343793)

VSCode
  • Mac/Linux
    bash <(curl -Ls https://aka.ms/bicep/nightly-vsix.sh) --run-id 6631343793
  • Windows
    iex "& { $(irm https://aka.ms/bicep/nightly-vsix.ps1) } -RunId 6631343793"
Azure CLI
  • Mac/Linux
    bash <(curl -Ls https://aka.ms/bicep/nightly-cli.sh) --run-id 6631343793
  • Windows
    iex "& { $(irm https://aka.ms/bicep/nightly-cli.ps1) } -RunId 6631343793"

@miqm miqm deleted the feat/decorators-on-nested-resources branch March 19, 2024 07:14
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.

Allow decorators on nested child-resources
2 participants