<!-- FIXME change it to the project's website -->
<url>http://www.example.com</url>
- <!--
<developers>
<developer>
<name>successli</name>
<url>https://github.com/successli</url>
</developer>
</developers>
- -->
<properties>
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
<artifactId>maven-deploy-plugin</artifactId>
<version>2.8.2</version>
</plugin>
+ <plugin>
+ <groupId>org.apache.maven.plugins</groupId>
+ <artifactId>maven-source-plugin</artifactId>
+ <version>2.2.1</version>
+ <executions>
+ <execution>
+ <id>attach-sources</id>
+ <goals>
+ <goal>jar-no-fork</goal>
+ </goals>
+ </execution>
+ </executions>
+ </plugin>
+ <plugin>
+ <groupId>org.apache.maven.plugins</groupId>
+ <artifactId>maven-javadoc-plugin</artifactId>
+ <version>2.9.1</version>
+ <executions>
+ <execution>
+ <id>attach-javadocs</id>
+ <goals>
+ <goal>jar</goal>
+ </goals>
+ </execution>
+ </executions>
+ </plugin>
</plugins>
</pluginManagement>
<plugins>
<target>7</target>
</configuration>
</plugin>
+ <plugin>
+ <artifactId>maven-assembly-plugin</artifactId>
+ <configuration>
+ <!--这部分可有可无,加上的话则直接生成可运行jar包-->
+ <!--<archive>-->
+ <!--<manifest>-->
+ <!--<mainClass>${exec.mainClass}</mainClass>-->
+ <!--</manifest>-->
+ <!--</archive>-->
+ <descriptorRefs>
+ <descriptorRef>jar-with-dependencies</descriptorRef>
+ </descriptorRefs>
+ <!-- mvn assembly:assembly -Dmaven.test.skip=true -->
+ <!-- mvn javadoc:javadoc -->
+ </configuration>
+ </plugin>
</plugins>
+ <resources>
+ <resource>
+ <directory>src/main/resources</directory>
+ <filtering>true</filtering>
+ </resource>
+ </resources>
</build>
</project>
Type listType = new ParameterizedTypeImpl(List.class, new Class[]{Key.class});
List<Key> keyList = client.request("list-keys", null, listType);
logger.info("list-key:");
- logger.info("size fo key:"+keyList.size());
+ logger.info("size of key:"+keyList.size());
logger.info(keyList);
return keyList;
}
* @param newPwd new password used to set
* @throws BytomException BytomException
*/
- public static void resetPwd(Client client, String xpub, String oldPwd, String newPwd) throws BytomException {
+ public static void resetPassword(Client client, String xpub, String oldPwd, String newPwd) throws BytomException {
Map<String, String> req = new HashMap<>();
req.put("xpub", xpub);
req.put("old_password", oldPwd);
}
@Test
- public void testClientKeyResetPwd() throws BytomException {
+ public void testClientKeyResetPassword() throws BytomException {
client = TestUtils.generateClient();
List<Key> keyList = Key.list(client);
String xpub = keyList.get(keyList.size()-1).xpub;
- Key.resetPwd(client, xpub, "123456", "123456789");
+ Key.resetPassword(client, xpub, "123456", "123456789");
Key.delete(client, xpub, "123456789");
}