TeacherUI:Almost completed and the test of DateBase didn't happen problem.But the test with ggb will not start.

This commit is contained in:
cccccyb
2022-06-12 03:25:34 +08:00
parent ff2e931291
commit 46935bdaba
7 changed files with 188 additions and 64 deletions

View File

@@ -0,0 +1,32 @@
package com.cfive.classroom.teacher;
import com.cfive.classroom.library.database.DatabaseHelper;
import com.cfive.classroom.library.database.util.DependenciesNotFoundException;
import com.cfive.classroom.library.database.util.NoConfigException;
import org.apache.logging.log4j.LogManager;
import org.apache.logging.log4j.Logger;
import org.junit.jupiter.api.Test;
import java.security.NoSuchAlgorithmException;
import java.security.spec.InvalidKeySpecException;
import java.sql.SQLException;
public class TeacherTest {
private static final Logger LOGGER = LogManager.getLogger();
@Test
void modifyPw(){
try {
DatabaseHelper.changePasswdInTeacher(Long.valueOf("1002"),"10021002");
} catch (NoConfigException e) {
throw new RuntimeException(e);
} catch (SQLException e) {
throw new RuntimeException(e);
} catch (DependenciesNotFoundException e) {
throw new RuntimeException(e);
} catch (NoSuchAlgorithmException e) {
throw new RuntimeException(e);
} catch (InvalidKeySpecException e) {
throw new RuntimeException(e);
}
}
}