jdk/test/sun/security/pkcs11/MessageDigest/ReinitDigest.java
changeset 35379 1e8e336ef66b
parent 30046 cf2c86e1819e
child 40975 680639c9b307
--- a/jdk/test/sun/security/pkcs11/MessageDigest/ReinitDigest.java	Tue Jan 26 09:25:53 2016 +0000
+++ b/jdk/test/sun/security/pkcs11/MessageDigest/ReinitDigest.java	Tue Jan 26 13:32:07 2016 -0800
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 2003, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2003, 2016, Oracle and/or its affiliates. All rights reserved.
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
  *
  * This code is free software; you can redistribute it and/or modify it
@@ -28,18 +28,22 @@
  * @author Andreas Sterbenz
  * @library ..
  * @key randomness
+ * @run main/othervm ReinitDigest
+ * @run main/othervm ReinitDigest sm
  */
 
-import java.util.*;
-
-import java.security.*;
+import java.security.MessageDigest;
+import java.security.Provider;
+import java.util.Arrays;
+import java.util.Random;
 
 public class ReinitDigest extends PKCS11Test {
 
     public static void main(String[] args) throws Exception {
-        main(new ReinitDigest());
+        main(new ReinitDigest(), args);
     }
 
+    @Override
     public void main(Provider p) throws Exception {
         if (p.getService("MessageDigest", "MD5") == null) {
             System.out.println("Provider does not support MD5, skipping");