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.
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
XLS-80d Permissioned Domains #773
XLS-80d Permissioned Domains #773
Changes from 88 commits
c7e1a15
9d549c1
8375c42
8d810fc
0a33121
fd8157d
1d85bbb
8ea12c4
e4293be
60b7663
509ecd1
c0151c2
48b8abc
f476a51
8b82c3d
a24ca5b
4402f6d
22de7a3
f848bbd
cb63c6d
ffcf1bd
e498721
e5a0779
ad4331a
1a974fb
880a670
af67d78
c50d611
2c887aa
8468fcd
bba054d
6c0b958
7f68440
1485ae9
27f8719
485d392
562aa49
d83f0d7
a188c1a
b97d6f3
379620a
e63b49d
5425b37
3e8b825
4106236
6e42798
0719107
f1d2b4e
bf5114a
6d8f1be
8e496e1
5656080
b43aa12
6392351
4ad028b
1f25b01
a870f2d
a6ac0f4
111e12a
8593111
7fa47e1
3d66a36
2d86ea2
f58dc2c
0f7f745
b02f902
b70ac84
7f79596
3814a94
c721a87
c76b755
9b7d17c
5068266
8abf7b7
26ea9b6
e5ad6c1
b7cd2b0
7549e48
5bdbf55
12d7075
fb98fd5
f65ba6b
e00d485
19c3caa
d42ebb9
cb9ec77
bc8954b
adf52d3
20762f8
c3a15b9
55239ba
39ec51e
abd94f3
489255e
084d876
7069c8d
b7a185a
3cddf4b
7e9fdfb
8206d73
File filter
Filter by extension
Conversations
Jump to
There are no files selected for viewing
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.
This is not necessary. You can create a Permissioned Domain without any credentials existing for it.
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.
that is true, but I'd like to test for a
tesSUCCESS
code at the end. If the credential-object doesn't exist, I wasn't sure if rippled throws an error.Besides, this displays the general workflow with PD
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.
The credential object does not need to exist. In fact, there's no way for rippled to check for it, since the subject could be anybody.
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.
Nonetheless, a re-usable credential in the integration test cases would be useful for upcoming amendments. I prefer to retain this piece of code.
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 agree with @mvadari . We should only add necessary things for tests. If I didn't have context on this feature, I would also assume a credential object is required for this to work.
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.
Are you guys suggesting that I create a
PermissionedDomain
object which cannot be amenable with anyCredential
object? That is ill-advised.Integration tests serve as useful examples for developers. Your suggestion mis-directs the developer and understates the importance of valid
Credential
s. The education of the end-user should take precedence over DGE team's ease-of-understanding.@mvadari In a typical scenario, a user interacts with this
PermissionedDomain
object, apart from thePDSet
andPDDelete
transactions. Surely, those interactions will fail without a valid credential.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'm suggesting not creating a credential in this file, and only creating it as needed. If you need a credential in the PD tests, then create a credential there, not here.
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.
💡 Codebase verification
Missing unit tests for PermissionedDomainDelete and domain_id validation
Based on the verification:
PermissionedDomainDelete
(only integration tests)domain_id
is defined as an optional string without validation in the modeldomain_id
caseRequired test additions:
tests/unit/models/transactions/test_permissioned_domain_delete.py
for unit testing the delete transactiondomain_id
validation in both transaction types:🔗 Analysis chain
Enhance test coverage for edge cases and related functionality.
The test suite could benefit from additional test cases:
domain_id
format validationPermissionedDomainDelete
transaction as mentioned in the PR objectivesLet's check if there are any tests for
PermissionedDomainDelete
:Would you like me to help generate:
🏁 Scripts executed
The following scripts were executed for the analysis:
Script:
Length of output: 98
Script:
Length of output: 665
Script:
Length of output: 408
Script:
Length of output: 64
Script:
Length of output: 111
Script:
Length of output: 195
Script:
Length of output: 548
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.
^
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.
@mvadari Thanks for confirming! Would you like me to help generate:
PermissionedDomainDelete
?domain_id
validation in both transaction types?🐰 thoughtfully nods
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.
@ckeshava bump
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.
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.
added unit tests in 489255e
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.
@mvadari thanks for the reminder, missed it