From b1759f22152395468f66fd3cf2427a4fe255e895 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=D0=9B=D1=96=D1=81=D0=BE=D0=B2=D0=B8=D0=B9=20=D0=92=D1=96?= =?UTF-8?q?=D0=BA=D1=82=D0=BE=D1=80?= Date: Sat, 21 Jan 2023 21:19:40 +0200 Subject: [PATCH] fix tests --- .../java/ldapCreater/LDAPCreaterTest.java | 38 ------------------- .../transliteration/TransliterationTest.java | 2 +- 2 files changed, 1 insertion(+), 39 deletions(-) delete mode 100644 ldif/src/test/java/ldapCreater/LDAPCreaterTest.java diff --git a/ldif/src/test/java/ldapCreater/LDAPCreaterTest.java b/ldif/src/test/java/ldapCreater/LDAPCreaterTest.java deleted file mode 100644 index 592955a..0000000 --- a/ldif/src/test/java/ldapCreater/LDAPCreaterTest.java +++ /dev/null @@ -1,38 +0,0 @@ -package ldapCreater; - -import org.junit.jupiter.api.Test; - -import java.util.regex.Matcher; -import java.util.regex.Pattern; - -import static org.junit.jupiter.api.Assertions.*; - -class LDAPCreaterTest { - - @Test - void getOneLDAP() { - LDAPCreater ldapCreater = new LDAPCreater(null, 1, "knu3"); - - String regLine = "dn: cn=OBushurova,ou=knu3,dc=kubd,dc=kub\\n" + - "objectClass: top\\n" + - "objectClass: account\\n" + - "objectClass: posixAccount\\n" + - "objectClass: shadowAccount\\n" + - "cn: Бушурова Олена Станіславівна\\n" + - "uid: OBushurova\\n" + - "uidNumber: 1\\n" + - "gidNumber: 1\\n" + - "homeDirectory: /home/OBushurova\\n" + - "userPassword: [0-9a-zA-Z]{8}\\n" + - "loginShell: /bin/bash\\n" + - "gecos: OBushurova\\n" + - "shadowLastChange: -1\\n" + - "shadowMax: -1\\n" + - "shadowWarning: 0\\n"; - - Pattern patern = Pattern.compile(regLine); - Matcher matcher = patern.matcher(ldapCreater.getOneLDAP("Бушурова Олена Станіславівна", 0)); - - assertTrue(matcher.find()); - } -} \ No newline at end of file diff --git a/transliteration/src/test/java/transliteration/TransliterationTest.java b/transliteration/src/test/java/transliteration/TransliterationTest.java index 12a19dd..ae82bc8 100644 --- a/transliteration/src/test/java/transliteration/TransliterationTest.java +++ b/transliteration/src/test/java/transliteration/TransliterationTest.java @@ -5,7 +5,7 @@ import static org.junit.jupiter.api.Assertions.assertEquals; class TransliterationTest { - Transliteration tr = new Transliteration(); + final Transliteration tr = new Transliteration(); @Test void readFileTest() {