diff --git a/build.gradle b/build.gradle index 413d147..b7446c7 100644 --- a/build.gradle +++ b/build.gradle @@ -59,7 +59,7 @@ dependencies { testCompile(files("../jcardsim/jcardsim-3.0.5-SNAPSHOT.jar")) testCompile('org.web3j:core:2.3.1') testCompile('org.bitcoinj:bitcoinj-core:0.14.5') - testCompile('com.github.status-im.status-keycard-java:desktop:15a61e1') + testCompile('com.github.status-im.status-keycard-java:desktop:3.1.2') testCompile('org.bouncycastle:bcprov-jdk15on:1.65') testCompile("org.junit.jupiter:junit-jupiter-api:5.1.1") testRuntime("org.junit.jupiter:junit-jupiter-engine:5.1.1") diff --git a/buildSrc/build.gradle b/buildSrc/build.gradle index 44786a5..3e21886 100644 --- a/buildSrc/build.gradle +++ b/buildSrc/build.gradle @@ -4,5 +4,5 @@ repositories { } dependencies { - compile 'com.github.status-im.status-keycard-java:desktop:15a61e1' + compile 'com.github.status-im.status-keycard-java:desktop:3.1.2' } \ No newline at end of file diff --git a/src/test/java/im/status/keycard/KeycardTest.java b/src/test/java/im/status/keycard/KeycardTest.java index 38b3be1..2e2a84e 100644 --- a/src/test/java/im/status/keycard/KeycardTest.java +++ b/src/test/java/im/status/keycard/KeycardTest.java @@ -128,9 +128,9 @@ private static void initCapabilities(ApplicationInfo info) { capabilities.add("ndef"); } - //if (info.hasFactoryResetCapability()) { + if (info.hasFactoryResetCapability()) { capabilities.add("factoryReset"); - //} + } CapabilityCondition.availableCapabilities = capabilities; } @@ -951,7 +951,8 @@ void factoryResetTest() throws Exception { APDUResponse response = sdkChannel.send(new APDUCommand(0x80, KeycardApplet.INS_FACTORY_RESET, 0, 0, new byte[0])); assertEquals(0x6a86, response.getSw()); - response = sdkChannel.send(new APDUCommand(0x80, KeycardApplet.INS_FACTORY_RESET, 0xAA, 0x55, new byte[0])); + // Good case + response = cmdSet.factoryReset(); assertEquals(0x9000, response.getSw()); response = cmdSet.getStatus(KeycardCommandSet.GET_STATUS_P1_KEY_PATH);