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: Allow DID controller switching [DEV-3587] #481

Merged
merged 11 commits into from
Feb 6, 2024
Merged

Conversation

lampkin-diet
Copy link
Contributor

@lampkin-diet lampkin-diet commented Jan 24, 2024

  • Add an ability to pass not the default keys to sign fr did update and deactivate and resource creation

@ankurdotb
Copy link
Contributor

Comment on lines 58 to 60
function mustIncludeKey(didResponse: ResponseBody, keyRef: string): boolean {
return didResponse.controllerKeys.some((key) => key.kid === keyRef);
}
Copy link
Contributor

Choose a reason for hiding this comment

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

The naming convention is ambiguous here.

The expected must<perform-action> literal indicates the closure throws if the operation fails, which is not the case here.

I appreciate this is a test helper, therefore won't probably confuse end users, hence why marking as non-blocking to promote.

Comment on lines 62 to 64
function mustIncludeKeyControllerRef(didResponse: ResponseBody, keyRef: string): boolean {
return didResponse.controllerKeyRefs.some((key) => key === keyRef);
}
Copy link
Contributor

Choose a reason for hiding this comment

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

Similar naming convention logic remark as above.

Copy link
Contributor

@Eengineer1 Eengineer1 left a comment

Choose a reason for hiding this comment

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

Very good demonstration on TDD defining + addressing interconnected and / or interchangeable identifier update scenarios.

There are relatively minor remarks to resolve, which should be quick to modify, before that's ready to promote.

PS: Cool + exhaustive testing sequence!

tests/e2e/did/switch-controller-flow.spec.ts Outdated Show resolved Hide resolved
tests/e2e/did/switch-controller-flow.spec.ts Outdated Show resolved Hide resolved
tests/e2e/did/switch-controller-flow.spec.ts Outdated Show resolved Hide resolved
tests/e2e/did/switch-controller-flow.spec.ts Outdated Show resolved Hide resolved
tests/e2e/did/switch-controller-flow.spec.ts Outdated Show resolved Hide resolved
tests/e2e/did/switch-controller-flow.spec.ts Outdated Show resolved Hide resolved
tests/e2e/did/switch-controller-flow.spec.ts Outdated Show resolved Hide resolved
tests/e2e/did/switch-controller-flow.spec.ts Outdated Show resolved Hide resolved
src/services/identity/abstract.ts Show resolved Hide resolved
src/services/identity/postgres.ts Show resolved Hide resolved
Copy link
Contributor

@Eengineer1 Eengineer1 left a comment

Choose a reason for hiding this comment

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

Looks well polished.

Approved.

@Eengineer1 Eengineer1 merged commit 2ef5b09 into develop Feb 6, 2024
14 checks passed
@Eengineer1 Eengineer1 deleted the DEV-3587 branch February 6, 2024 15:18
cheqd-bot bot pushed a commit that referenced this pull request Feb 14, 2024
## [2.17.0-develop.1](2.16.1-develop.1...2.17.0-develop.1) (2024-02-14)

### Features

* Allow DID controller switching [DEV-3587] ([#481](#481)) ([2ef5b09](2ef5b09))
@cheqd-bot
Copy link

cheqd-bot bot commented Feb 14, 2024

🎉 This PR is included in version 2.17.0-develop.1 🎉

The release is available on:

Your semantic-release bot 📦🚀

cheqd-bot bot pushed a commit that referenced this pull request Feb 19, 2024
## [2.17.0](2.16.0...2.17.0) (2024-02-19)

### Features

* Allow DID controller switching [DEV-3587] ([#481](#481)) ([2ef5b09](2ef5b09))

### Bug Fixes

* Add creds decryption .env ([#475](#475)) ([d332764](d332764))
@cheqd-bot
Copy link

cheqd-bot bot commented Feb 19, 2024

🎉 This PR is included in version 2.17.0 🎉

The release is available on:

Your semantic-release bot 📦🚀

@cheqd-bot cheqd-bot bot added the released label Feb 19, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Development

Successfully merging this pull request may close these issues.

3 participants