Skip to content

Improve module naming testing & reporting#3790

Merged
danielrbradley merged 5 commits into
masterfrom
provider-naming
Dec 14, 2024
Merged

Improve module naming testing & reporting#3790
danielrbradley merged 5 commits into
masterfrom
provider-naming

Conversation

@danielrbradley

@danielrbradley danielrbradley commented Dec 13, 2024

Copy link
Copy Markdown
Contributor

Working towards: #690

  1. Refine existing tests and extend coverage
  2. Add reporting of skipped file paths

Summary of report findings where file and uri calculated names don't match

file: Authorization, uri: ""

Count: 31

file: KeyVault, uri: Resources

Count: 16

###: file: Maps, uri: Resources

Count: 2

file: Network, uri: Compute

Count: 522
File paths: specification/network/resource-manager/Microsoft.Network/*/*/vmssPublicIpAddress.json:
Resource paths:

  • `.../providers/microsoft.Compute/virtualMachineScaleSets/{virtualMachineScaleSetName}/.../networkInterfaces
  • providers/microsoft.Compute/virtualMachineScaleSets/{virtualMachineScaleSetName}/.../ipConfigurations/{ipConfigurationName}"

file: NotificationHubs, uri: ""

Count: 1

file: PowerBI, uri: Resources

Count: 1

file: Authorization, uri: ""

Count: 31
Path: "/{policyAssignmentId}"

file: Resources, uri: Authorization

Count: 6
Path: ".../providers/Microsoft.Authorization/policyAssignments"

file: Resources, uri: ""

Count: 52
Path: "/providers" or "/{resourceId}"

file: Resources, uri: Management

Count: 9
Path: "/providers/Microsoft.Management/managementGroups/{groupId}/providers/{resourceProviderNamespace}/register

file: Solutions, uri: ""

Count: 18
Path: "/{applicationId}"

file: SaaS, uri: Resources

Count: 2
Path: "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/moveResources|validateMoveResources"

file: Web, uri: CertificateRegistration

Count: 12

file: Web, uri: DomainRegistration

Count: 11

file: Web, uri: Resources

Count: 33

Web, uri: CertificateRegistration

Count: 12

@danielrbradley danielrbradley self-assigned this Dec 13, 2024
@github-actions

Copy link
Copy Markdown
Contributor

Does the PR have any schema changes?

Looking good! No breaking changes found.
No new resources/functions.

@codecov

codecov Bot commented Dec 13, 2024

Copy link
Copy Markdown

Codecov Report

Attention: Patch coverage is 88.88889% with 2 lines in your changes missing coverage. Please review.

Project coverage is 57.00%. Comparing base (9400ed0) to head (d8ad612).
Report is 6 commits behind head on master.

Files with missing lines Patch % Lines
provider/pkg/versioning/build_schema.go 0.00% 2 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##           master    #3790      +/-   ##
==========================================
+ Coverage   56.96%   57.00%   +0.03%     
==========================================
  Files          78       78              
  Lines       12018    12029      +11     
==========================================
+ Hits         6846     6857      +11     
- Misses       4672     4673       +1     
+ Partials      500      499       -1     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@danielrbradley danielrbradley changed the title Improve module naming flexibility Improve module naming testing & reporting Dec 13, 2024
@danielrbradley danielrbradley requested review from a team and thomas11 December 13, 2024 13:49
@danielrbradley danielrbradley marked this pull request as ready for review December 13, 2024 13:50

@thomas11 thomas11 left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Why do most of the reports in the PR descriptions lack Path and FilePath?

Comment thread provider/pkg/openapi/discover.go
@danielrbradley

Copy link
Copy Markdown
Contributor Author

Why do most of the reports in the PR descriptions lack Path and FilePath?

That's just poor formatting on my side ... i.e. it's

  • file: Network
  • uri: Compute

These are absolute at runtime, so should be reflected in the test.
This is the "new style" but it's opt-in for only a specific list of modules.
- Add error return from ResourceProvider naming function.
- Add entry to DiscoveryDiagnostics & BuildSchemaReports.
@pulumi-bot

Copy link
Copy Markdown
Contributor

This PR has been shipped in release v2.78.0.

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.

3 participants