-
Notifications
You must be signed in to change notification settings - Fork 10
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
fix: fixed integration tests with attested object #290
Merged
Conversation
This file contains 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
Coverage report for
|
St.❔ |
Category | Percentage | Covered / Total |
---|---|---|---|
🟡 | Statements | 72.25% (+1.59% 🔼) |
1906/2638 |
🔴 | Branches | 45.28% | 254/561 |
🟡 | Functions | 78.48% (+2.69% 🔼) |
350/446 |
🟡 | Lines | 72.46% (+1.63% 🔼) |
1868/2578 |
Show files with reduced coverage 🔻
St.❔ |
File | Statements | Branches | Functions | Lines |
---|---|---|---|---|---|
🟢 | libs/utils.ts | 87.16% | 65.28% (-1.39% 🔻) |
94.12% | 88.44% |
🟡 | ... / IdentifierAttestation.ts |
76.09% (-3.26% 🔻) |
43.75% (-12.5% 🔻) |
86.67% | 77.78% (-3.33% 🔻) |
🟡 | libs/Timestamp.ts | 73.81% (-4.76% 🔻) |
44.44% (-11.11% 🔻) |
70% | 73.17% (-4.88% 🔻) |
Test suite run success
38 tests passing in 2 suites.
Report generated by 🧪jest coverage report action from eb2c4ba
oleggrib
approved these changes
Aug 24, 2022
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.
Looks good, thank you!
jot2re
added a commit
that referenced
this pull request
Nov 14, 2022
* feat: added sourcify-verify * chore: remove stub empty line * fix: 🐛 issue#276 fix. Added eip712 domain validations ✅ Closes: #276 * docs: ✏️ removed commented code, added comment to explain undef * fix: 🐛 add getters/setters for EIP712 params * ci: 🎡 trigger tn CI after prerelease * test: adding dumping of generated material for tests in attestation.jar (#283) * test: implemented an object dumber and updated java tests to write object dumps, along with handling linter feedback on the touched files * ci: 🎡 trigger tn CI after prerelease Co-authored-by: Tore Kasper Frederiksen <[email protected]> Co-authored-by: Feng Yu <[email protected]> * bug: added domain validation to AttestationUsage and AttestationRequestWUsage (#285) * ci: 🎡 trigger tn CI after prerelease * test: adding dumping of generated material for tests in attestation.jar (#283) * test: implemented an object dumber and updated java tests to write object dumps, along with handling linter feedback on the touched files * ci: 🎡 trigger tn CI after prerelease Co-authored-by: Tore Kasper Frederiksen <[email protected]> Co-authored-by: Feng Yu <[email protected]> * bug: added domain validation to AttestationUsage and AttestationRequestWUsage * fix: 🐛 issue#276 fix. Added eip712 domain validations ✅ Closes: #276 * docs: ✏️ removed commented code, added comment to explain undef * fix: 🐛 add getters/setters for EIP712 params Co-authored-by: Feng Yu <[email protected]> Co-authored-by: Tore Kasper Frederiksen <[email protected]> Co-authored-by: Oleh Hryb <[email protected]> * fix: added domain validation to AttestationRequestWithUsage and AttestationUsage * fix: 🐛 asn_decoding fix(patch), attestation timestamp check (#273) Added patch to fix ASN1_schema bug for Integers, added Attestation validate timestamp * fix: fixed integration tests with attested object (#290) Co-authored-by: Tore Kasper Frederiksen <[email protected]> * fix: updated peculiar asn1 to latest version which contains the fix that is otherwise included in the patch (#294) Co-authored-by: Tore Kasper Frederiksen <[email protected]> * feat: signature-based UN and possibility of adding context to UN (#284) * feat: wrote a UN based on signature and refactored things to allow an optional context for both MAC-based UNs and signature-based UNs * test: adding dumping of generated material for tests in attestation.jar (#283) * test: implemented an object dumber and updated java tests to write object dumps, along with handling linter feedback on the touched files * ci: 🎡 trigger tn CI after prerelease Co-authored-by: Tore Kasper Frederiksen <[email protected]> Co-authored-by: Feng Yu <[email protected]> * feat: wrote a UN based on signature and refactored things to allow an optional context for both MAC-based UNs and signature-based UNs * docs: added comments * fix: made some fixes and tried to get a consistent version working between TS and Java * fix: updated java code to be able to integration test JS generated UNs * fix: updated JS code to be able to integration test with java generated UNs and added tests * Removed unnneeded test * test: updated tests and ensured consistent and deterministic code when needed * test: updated and expanded integration tests to ensure consistency with Java implementation * fix: fixed issues related to deterministic keys * test: fixed missing references in js test * fix: fixed directory typo Co-authored-by: Feng Yu <[email protected]> * feat: ✨ safeconnect (#279) * docs(core): adding asn1 draft for nftownership attestation and ethereum linking attestation * docs(core): adding asn1 draft for nftownership attestation and ethereum linking attestation in asd format as well * docs(core): fixed typos in old asd format * docs(core): updates description to reuse old type for erc721 token * docs(core): updated asn format description after discussion with Miccy * docs(core): fixed bug in old asn1 notation * docs(core): updated asd format too * refactor:core refactored representation of erc721 tokens to fit with what we also need * feat(core): added first draft of signed NFT Ownership Attestation * test(core): added sunshine tests to signed NFT Ownership Attestation * Draft JS schemas. * Bump version - JS patch release 0.3.8 * fix(core): updated format to match the new format from Miccy * Update JS schemas for safe connect. * feat(core) added draft of ethereum key link attestation along with refactoring * fix(core) added missing file * feat(core) added draft of ethereum address attestation * refactor(core) removed redundant decoder code * test(core) added test to ownership attestations * test(core) added test to key linking attestation * Fixes for node.js support - Fix window debug ENV check. - Fix uint8array to base64 encoding. * refactor: refactoring and improved testing * test: added more testing along with file writing and reading of test data * fix: changed to assume the issuer uses Ethereum keys and refactored OID identification * fix: updated failing tests * Migrate safe connect attestation and verification code WIP. * Migrate safe connect attestation and verification code WIP. * Migrate safe connect attestation and verification code WIP. * Fix parsing * Add validity checking & optional parameter validFrom. * feat: move smart contract * chore: Refactor test attestations to be generated using javascript lib. * chore: Add javascript lib tests * feature: NFT Attestation solidity library * chore: Add test mint contract & fix attestation validity issues with tests. * fix: added missing tag to java version * fix: added fixes to get the MVP integration working * test: added integration test for JS safeconnect version * feature: JS context & various other enhancements - Add optional context field to Javascript attestation creation. - Move signing function to AbstractLinkedAttestation. - Add multi-token support to JS NFT attestation creation. - Implement test to validate Java attestation in Javascript. - Add method to get linked attestation data from EthereumKeyLinkingAttestation. * chore: Bump JS pre-release version to 0.3.9-sc.3 * test: added more safeconnect integration tests * test: added integration test of JS with Java * test: added console printing of right value * fix: missing NFT_ADDRESS variable in test * test: enable JS -> Java test * feat: made chainID mandatory on ERC721 tokens * fix: make github CI/CD pass * fix: added schema for address linking * refactor: improved variable naming * feat: added support for array of tokens in java version * feature: multi-token ID support for JS and solidity library. * refactor: changed format of Erc721 token to have IDs at the end and always store things as an array * test: updated java test * chore: bump version * fix: silly bug :-( * fix: context field type * test: added test for context * test: added test for context * fix: issuer keys being overwritten when provided in base64/PEM format feat: return attested object in validateUseTicket function. * fix: remove temporary patch for asn1-schema integer parsing issue ref: ae8c45b updated peculiar asn1 to latest version which contains the fix that is otherwise included in the patch (#294). Co-authored-by: Michael Wallace <[email protected]> Co-authored-by: snowwhitedev <[email protected]> * update contracts to use standard ERC721 and in-line library to reduce gas cost. Also update tests in line with these changes (#292) * Various fixes & enhancements for Devcon use cases (#297) * feature: validateUseTicket - allow validation to skip ethAddress check. Allow skipping of ethereum address by explicitly passing null as userEthKey value. * Bump version for devcon release * Bump version for devcon release * feature: add getDevconId function to Ticket class * build: updated dependencies * build: updated dependencies * build: updated version * build: updated version * Devcon (#299) * feature: validateUseTicket - allow validation to skip ethAddress check. Allow skipping of ethereum address by explicitly passing null as userEthKey value. * Bump version for devcon release * Bump version for devcon release * feature: add getDevconId function to Ticket class * feature: allow multiple keys for validation of a single conference ID * fix/disabled blockchain enabled tests (#303) * build: upgraded dependencies Co-authored-by: snowwhitedev <[email protected]> Co-authored-by: oleggrib <[email protected]> Co-authored-by: Feng Yu <[email protected]> Co-authored-by: Michael Wallace <[email protected]> Co-authored-by: James Brown <[email protected]>
jot2re
added a commit
that referenced
this pull request
Nov 17, 2022
* feat: added sourcify-verify * chore: remove stub empty line * fix: 🐛 issue#276 fix. Added eip712 domain validations ✅ Closes: #276 * docs: ✏️ removed commented code, added comment to explain undef * fix: 🐛 add getters/setters for EIP712 params * ci: 🎡 trigger tn CI after prerelease * test: adding dumping of generated material for tests in attestation.jar (#283) * test: implemented an object dumber and updated java tests to write object dumps, along with handling linter feedback on the touched files * ci: 🎡 trigger tn CI after prerelease Co-authored-by: Tore Kasper Frederiksen <[email protected]> Co-authored-by: Feng Yu <[email protected]> * bug: added domain validation to AttestationUsage and AttestationRequestWUsage (#285) * ci: 🎡 trigger tn CI after prerelease * test: adding dumping of generated material for tests in attestation.jar (#283) * test: implemented an object dumber and updated java tests to write object dumps, along with handling linter feedback on the touched files * ci: 🎡 trigger tn CI after prerelease Co-authored-by: Tore Kasper Frederiksen <[email protected]> Co-authored-by: Feng Yu <[email protected]> * bug: added domain validation to AttestationUsage and AttestationRequestWUsage * fix: 🐛 issue#276 fix. Added eip712 domain validations ✅ Closes: #276 * docs: ✏️ removed commented code, added comment to explain undef * fix: 🐛 add getters/setters for EIP712 params Co-authored-by: Feng Yu <[email protected]> Co-authored-by: Tore Kasper Frederiksen <[email protected]> Co-authored-by: Oleh Hryb <[email protected]> * fix: added domain validation to AttestationRequestWithUsage and AttestationUsage * fix: 🐛 asn_decoding fix(patch), attestation timestamp check (#273) Added patch to fix ASN1_schema bug for Integers, added Attestation validate timestamp * fix: fixed integration tests with attested object (#290) Co-authored-by: Tore Kasper Frederiksen <[email protected]> * fix: updated peculiar asn1 to latest version which contains the fix that is otherwise included in the patch (#294) Co-authored-by: Tore Kasper Frederiksen <[email protected]> * feat: signature-based UN and possibility of adding context to UN (#284) * feat: wrote a UN based on signature and refactored things to allow an optional context for both MAC-based UNs and signature-based UNs * test: adding dumping of generated material for tests in attestation.jar (#283) * test: implemented an object dumber and updated java tests to write object dumps, along with handling linter feedback on the touched files * ci: 🎡 trigger tn CI after prerelease Co-authored-by: Tore Kasper Frederiksen <[email protected]> Co-authored-by: Feng Yu <[email protected]> * feat: wrote a UN based on signature and refactored things to allow an optional context for both MAC-based UNs and signature-based UNs * docs: added comments * fix: made some fixes and tried to get a consistent version working between TS and Java * fix: updated java code to be able to integration test JS generated UNs * fix: updated JS code to be able to integration test with java generated UNs and added tests * Removed unnneeded test * test: updated tests and ensured consistent and deterministic code when needed * test: updated and expanded integration tests to ensure consistency with Java implementation * fix: fixed issues related to deterministic keys * test: fixed missing references in js test * fix: fixed directory typo Co-authored-by: Feng Yu <[email protected]> * feat: ✨ safeconnect (#279) * docs(core): adding asn1 draft for nftownership attestation and ethereum linking attestation * docs(core): adding asn1 draft for nftownership attestation and ethereum linking attestation in asd format as well * docs(core): fixed typos in old asd format * docs(core): updates description to reuse old type for erc721 token * docs(core): updated asn format description after discussion with Miccy * docs(core): fixed bug in old asn1 notation * docs(core): updated asd format too * refactor:core refactored representation of erc721 tokens to fit with what we also need * feat(core): added first draft of signed NFT Ownership Attestation * test(core): added sunshine tests to signed NFT Ownership Attestation * Draft JS schemas. * Bump version - JS patch release 0.3.8 * fix(core): updated format to match the new format from Miccy * Update JS schemas for safe connect. * feat(core) added draft of ethereum key link attestation along with refactoring * fix(core) added missing file * feat(core) added draft of ethereum address attestation * refactor(core) removed redundant decoder code * test(core) added test to ownership attestations * test(core) added test to key linking attestation * Fixes for node.js support - Fix window debug ENV check. - Fix uint8array to base64 encoding. * refactor: refactoring and improved testing * test: added more testing along with file writing and reading of test data * fix: changed to assume the issuer uses Ethereum keys and refactored OID identification * fix: updated failing tests * Migrate safe connect attestation and verification code WIP. * Migrate safe connect attestation and verification code WIP. * Migrate safe connect attestation and verification code WIP. * Fix parsing * Add validity checking & optional parameter validFrom. * feat: move smart contract * chore: Refactor test attestations to be generated using javascript lib. * chore: Add javascript lib tests * feature: NFT Attestation solidity library * chore: Add test mint contract & fix attestation validity issues with tests. * fix: added missing tag to java version * fix: added fixes to get the MVP integration working * test: added integration test for JS safeconnect version * feature: JS context & various other enhancements - Add optional context field to Javascript attestation creation. - Move signing function to AbstractLinkedAttestation. - Add multi-token support to JS NFT attestation creation. - Implement test to validate Java attestation in Javascript. - Add method to get linked attestation data from EthereumKeyLinkingAttestation. * chore: Bump JS pre-release version to 0.3.9-sc.3 * test: added more safeconnect integration tests * test: added integration test of JS with Java * test: added console printing of right value * fix: missing NFT_ADDRESS variable in test * test: enable JS -> Java test * feat: made chainID mandatory on ERC721 tokens * fix: make github CI/CD pass * fix: added schema for address linking * refactor: improved variable naming * feat: added support for array of tokens in java version * feature: multi-token ID support for JS and solidity library. * refactor: changed format of Erc721 token to have IDs at the end and always store things as an array * test: updated java test * chore: bump version * fix: silly bug :-( * fix: context field type * test: added test for context * test: added test for context * fix: issuer keys being overwritten when provided in base64/PEM format feat: return attested object in validateUseTicket function. * fix: remove temporary patch for asn1-schema integer parsing issue ref: ae8c45b updated peculiar asn1 to latest version which contains the fix that is otherwise included in the patch (#294). Co-authored-by: Michael Wallace <[email protected]> Co-authored-by: snowwhitedev <[email protected]> * update contracts to use standard ERC721 and in-line library to reduce gas cost. Also update tests in line with these changes (#292) * Various fixes & enhancements for Devcon use cases (#297) * feature: validateUseTicket - allow validation to skip ethAddress check. Allow skipping of ethereum address by explicitly passing null as userEthKey value. * Bump version for devcon release * Bump version for devcon release * feature: add getDevconId function to Ticket class * build: updated dependencies * build: updated dependencies * build: updated version * build: updated version * Devcon (#299) * feature: validateUseTicket - allow validation to skip ethAddress check. Allow skipping of ethereum address by explicitly passing null as userEthKey value. * Bump version for devcon release * Bump version for devcon release * feature: add getDevconId function to Ticket class * feature: allow multiple keys for validation of a single conference ID * fix/disabled blockchain enabled tests (#303) * build: upgraded dependencies * fix: 🐛 hotfix - updated @types/node * Fix/breaking change erc721 (#304) * fix: changes to use a legacy format for ERC721 for legacy alchemy NFT tokens * fix: added missing file * fix: fix javascript to also use legacy format in the legacy setting * build: updated versions * fix: reversal experiment to appease github actions * fix: second attempt * build: updated non-breaking dependencies * fix: changed access of ERC721 * fix: 🐛 hotfix - updated @types/node Co-authored-by: Oleh Hryb <[email protected]> Co-authored-by: snowwhitedev <[email protected]> Co-authored-by: oleggrib <[email protected]> Co-authored-by: Feng Yu <[email protected]> Co-authored-by: Michael Wallace <[email protected]> Co-authored-by: James Brown <[email protected]>
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
This closes issue #282