-
-
Notifications
You must be signed in to change notification settings - Fork 92
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
#542 Remove hard coded users details and read from csv file #1184
base: main
Are you sure you want to change the base?
Conversation
f0bd7cc
to
7c7cd5a
Compare
Kudos, SonarCloud Quality Gate passed! 0 Bugs No Coverage information |
@nicolas63 Can you please review this whenever you get time? |
templates: [ | ||
{ | ||
file: 'Project.Test/Configuration/users-data.csv', | ||
renameTo: generator => `${generator.testProjectDir}/bin/Debug/net6.0/Configuration/users-data.csv`, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
i think it's not the good way to copy the csv in generated folder, we need to copy this file during the build
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sure, I can take a look at an alternative to copy the file from main solution to test folder.
@@ -52,53 +72,10 @@ public static class IdentityConfiguration | |||
|
|||
private static IEnumerable<User> Users() |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
In this issue we want move role and user role association in a file
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Oh I thought it was users data which was required to be loaded from csv/json file. Now if I understand correctly, is it this piece of hardcoded values which needs to be in a file?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
yes and also this
Lines 47 to 50 in e58837f
{ | |
new Role {Id = "role_admin", Name = "ROLE_ADMIN"}, | |
new Role {Id = "role_user",Name = "ROLE_USER"} | |
}; |
i think we can create 1 file per list
Can you add documentation for this new feature ? |
Yes, @nicolas63 I'll add the relevant docs too. I'll also take a look at your requested changes. |
# Conflicts: # generators/server/templates/dotnetcore/src/Directory.Packages.props
7c7cd5a
to
efe65a6
Compare
Kudos, SonarCloud Quality Gate passed! 0 Bugs No Coverage information |
Please make sure the below checklist is followed for Pull Requests.
All continuous integration tests are green
Tests are added where necessary
Documentation is added/updated where necessary
Coding Rules & Commit Guidelines as per our CONTRIBUTING.md document are followed
Fixes #542