Skip to content

Commit

Permalink
[FAB-13167] IdemixBridgeTest Robustification
Browse files Browse the repository at this point in the history
This change-set updates the tests to always
correctly invalidate a credential in a bad path test.

Change-Id: I3a0eda33bf1158d7a1cf8a3ddd7dc4c4af5548dd
Signed-off-by: Angelo De Caro <adc@zurich.ibm.com>
  • Loading branch information
adecaro committed Dec 5, 2018
1 parent f63c95d commit 151f76e
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion bccsp/idemix/bridge/bridge_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -849,7 +849,13 @@ var _ = Describe("Idemix Bridge", func() {
})

It("invalid credential", func() {
credential[4] = 0
// Invalidate credential by changing it in one position
if credential[4] == 0 {
credential[4] = 1
} else {
credential[4] = 0
}

// Verify Credential
valid, err := CredentialVerifier.Verify(
UserKey,
Expand Down

0 comments on commit 151f76e

Please sign in to comment.