Refactor WithRealmImport to accept file or directory#7121
Merged
davidfowl merged 3 commits intomicrosoft:mainfrom Jan 19, 2025
Merged
Refactor WithRealmImport to accept file or directory#7121davidfowl merged 3 commits intomicrosoft:mainfrom
davidfowl merged 3 commits intomicrosoft:mainfrom
Conversation
Updated the `WithRealmImport` method to change the parameter name from `importDirectory` to `import`, allowing it to accept either a directory or a single import file. Adjusted the method logic to handle both cases and updated the XML documentation for clarity.
Updated `WithRealmImportShouldThrowWhenBuilderIsNull` test to check for null import instead of import directory, and changed the expected exception type for non-existent imports. Added a new configuration section in `Aspire.lutconfig` to enable parallel builds, parallel test runs, and set a test case timeout of 180 seconds.
3 tasks
DamianEdwards
requested changes
Jan 18, 2025
Removed obsolete configuration from Aspire.lutconfig. Added new parameterized tests in KeycloakPublicApiTests.cs for realm import functionality with directory and file inputs. Removed the outdated WithRealmImportAddsBindMountAnnotation test from KeycloakResourceBuilderTests.cs.
Open
3 tasks
DamianEdwards
approved these changes
Jan 18, 2025
davidfowl
reviewed
Jan 18, 2025
| public static IResourceBuilder<KeycloakResource> WithRealmImport( | ||
| this IResourceBuilder<KeycloakResource> builder, | ||
| string importDirectory, | ||
| string import, |
Contributor
There was a problem hiding this comment.
This is a breaking change if you use named parameters but this package is preview so care level is low 😄
Contributor
Author
There was a problem hiding this comment.
This is a breaking change if you use named parameters but this package is preview so care level is low 😄
Yes and yes. But I couldn't keep importDirectory when the semantics has changed.
Contributor
|
/azp run |
|
Azure Pipelines successfully started running 1 pipeline(s). |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
Updated the
WithRealmImportmethod to change the parameter name fromimportDirectorytoimport, allowing it to accept either a directory or a single import file. Adjusted the method logic to handle both cases and updated the XML documentation for clarity.Fixes #5086
/cc @davidfowl @DamianEdwards
Checklist
<remarks />and<code />elements on your triple slash comments?breaking-changetemplate):doc-ideatemplate):