discipl / core

Discipl Core
GNU General Public License v3.0
9 stars 8 forks source link

Extend the API with 'observeVerificationRequests' and an additional parameter #54

Closed n9iels closed 4 years ago

n9iels commented 4 years ago

Description

This PR add the observeVerificationRequests method to the API. This makes the implementation of connectors that require additional verification before a claim can be verified possible. An example of such a connector is IPv8 connector

Another change in this PR is an additional parameter for the claim method. This parameter, named attester, makes it possible to express the did of the expected attester. This makes it possible to implement a connector that requires both parties to be known when creating a claim.

Backwards compatibility

No breaking changes are made in this PR

n9iels commented 4 years ago

Adding integration tests is possible since there is already a implementation for this in the discipl-core-ipv8 repo itself.

I do need to say that the integration tests currently are not stable. Sometimes they randomly fail and after a restart they pass without any problems. I will take a look at that issue first (https://github.com/discipl/discipl-core-ipv8/issues/15), after that I will implement it here.

n9iels commented 4 years ago

@pimotte I added some integration tests for the IPv8 connector. Once the npm package is live and installed Travis should be happy too :smile:

sonarcloud[bot] commented 4 years ago

Kudos, SonarCloud Quality Gate passed!

Bug A 0 Bugs
Vulnerability A 0 Vulnerabilities (and Security Hotspot 0 Security Hotspots to review)
Code Smell A 0 Code Smells

100.0% 100.0% Coverage
0.0% 0.0% Duplication