package org.mvnsearch.totp;

import org.junit.Test;

/**
 * totp test
 *
 * @author linux_china
 */
public class TOTPTest {
    String randomCode = "1234567";

    @Test
    public void testGenerateUrl() throws Exception {
        System.out.println(TOTP.getAuthUrl("libing.chen@gmail.com", "mvnsearch", randomCode));
    }

    @Test
    public void testCheckCode() throws Exception {
        System.out.println(TOTP.checkCode(randomCode, 11616));
    }
}

@@ -22,16 +22,41 @@
 .totp;%0A%0A
+import org.junit.Assert;%0A
 import o
@@ -412,34 +412,33 @@
         
-System.out.println
+Assert.assertTrue
 (TOTP.ch
@@ -461,13 +461,14 @@
 de, 
-11616
+672468
 ));%0A

add assert