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

feat: Improve account loading errors #1669

Merged
merged 5 commits into from
Jan 17, 2025

Conversation

arthurpitman
Copy link
Contributor

@arthurpitman arthurpitman commented Jan 10, 2025

Found while investigating #1666, this PR:

  • reduces the complexity of load(...)
  • ensures file name is included in errors while loading account resources
  • corrects two typos in error messages
  • improves error messages
  • refactors code for increased readability

@arthurpitman arthurpitman added the run-iam-test Manually trigger Account Management E2E tests for PRs label Jan 10, 2025
Copy link

github-actions bot commented Jan 10, 2025

Unit Test Results

1 966 tests  ±0   1 965 ✅ ±0   54s ⏱️ ±0s
  135 suites ±0       1 💤 ±0 
    1 files   ±0       0 ❌ ±0 

Results for commit 2fc8a42. ± Comparison against base commit 43bd64a.

♻️ This comment has been updated with latest results.

Copy link

github-actions bot commented Jan 10, 2025

E2E Test Results

1 files   -     3  1 suites   - 271   19m 47s ⏱️ - 4m 58s
2 tests  - 2 083  2 ✅  - 2 081  0 💤  - 2  0 ❌ ±0 
2 runs   - 2 235  2 ✅  - 2 233  0 💤  - 2  0 ❌ ±0 

Results for commit 2fc8a42. ± Comparison against base commit 43bd64a.

This pull request removes 2085 and adds 2 tests. Note that renamed tests count towards both.
github.com/dynatrace/dynatrace-configuration-as-code/v2/cmd/monaco/account ‑ TestLoadResources
github.com/dynatrace/dynatrace-configuration-as-code/v2/cmd/monaco/account ‑ TestLoadResources_Duplicates
github.com/dynatrace/dynatrace-configuration-as-code/v2/cmd/monaco/account ‑ TestLoadResources_Duplicates/Load_Resources_-_duplicate_group
github.com/dynatrace/dynatrace-configuration-as-code/v2/cmd/monaco/account ‑ TestLoadResources_Duplicates/Load_Resources_-_duplicate_policy
github.com/dynatrace/dynatrace-configuration-as-code/v2/cmd/monaco/account ‑ TestLoadResources_Duplicates/Load_Resources_-_duplicate_user
github.com/dynatrace/dynatrace-configuration-as-code/v2/cmd/monaco/convert ‑ TestConvert_FailsIfThereIsJustEmptyProjects
github.com/dynatrace/dynatrace-configuration-as-code/v2/cmd/monaco/convert ‑ TestConvert_RemovesEscapeCharsAsV2AutoEscapes
github.com/dynatrace/dynatrace-configuration-as-code/v2/cmd/monaco/convert ‑ TestConvert_WorksIfNoDeleteYamlExists
github.com/dynatrace/dynatrace-configuration-as-code/v2/cmd/monaco/convert ‑ TestConvert_WorksOnFullConfiguration
github.com/dynatrace/dynatrace-configuration-as-code/v2/cmd/monaco/convert ‑ TestCopyDeleteFileIfPresent
…
github.com/dynatrace/dynatrace-configuration-as-code/v2/cmd/monaco/integrationtest/account ‑ TestDeployAndDelete_AllResources
github.com/dynatrace/dynatrace-configuration-as-code/v2/cmd/monaco/integrationtest/account ‑ TestIdempotenceOfDeployment

♻️ This comment has been updated with latest results.

@arthurpitman arthurpitman force-pushed the feat/improve-account-loading-errors branch from a344c2e to a002c32 Compare January 10, 2025 11:22
@arthurpitman arthurpitman marked this pull request as ready for review January 10, 2025 11:22
@arthurpitman arthurpitman requested a review from a team as a code owner January 10, 2025 11:22
@arthurpitman arthurpitman force-pushed the feat/improve-account-loading-errors branch 2 times, most recently from f827234 to 0edcd95 Compare January 17, 2025 12:20
@arthurpitman arthurpitman added run-iam-test Manually trigger Account Management E2E tests for PRs and removed run-iam-test Manually trigger Account Management E2E tests for PRs labels Jan 17, 2025
@arthurpitman arthurpitman force-pushed the feat/improve-account-loading-errors branch from 0edcd95 to 2fc8a42 Compare January 17, 2025 12:21
@arthurpitman arthurpitman added run-iam-test Manually trigger Account Management E2E tests for PRs and removed run-iam-test Manually trigger Account Management E2E tests for PRs labels Jan 17, 2025
@arthurpitman arthurpitman requested a review from jskelin January 17, 2025 12:22
Copy link
Contributor

@jskelin jskelin left a comment

Choose a reason for hiding this comment

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

lgtm

@arthurpitman arthurpitman added run-iam-test Manually trigger Account Management E2E tests for PRs and removed run-iam-test Manually trigger Account Management E2E tests for PRs labels Jan 17, 2025
@arthurpitman arthurpitman merged commit 228ac11 into main Jan 17, 2025
30 of 31 checks passed
@arthurpitman arthurpitman deleted the feat/improve-account-loading-errors branch January 17, 2025 14:04
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
run-iam-test Manually trigger Account Management E2E tests for PRs
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants