diff --git a/test/java/foundation/pEp/jniadapter/test/Makefile.conf b/test/java/foundation/pEp/jniadapter/test/Makefile.conf index ad81a1b..cff4624 100644 --- a/test/java/foundation/pEp/jniadapter/test/Makefile.conf +++ b/test/java/foundation/pEp/jniadapter/test/Makefile.conf @@ -28,6 +28,10 @@ JAVA_OPT_LIBARY_PATH=-Djava.library.path=$(LD_LIB_PATH) JAVA_OPTS=$(JAVA_OPT_ASSERTIONS) $(JAVA_OPT_XCHECK) $(JAVA_OPT_REMOTE_DEBUGGER) $(JAVA_OPT_CLASSPATH) $(JAVA_OPT_LIBARY_PATH) JAVA=java $(JAVA_OPTS) +UTIL_SOURCES=$(wildcard ../utils/*.java) +UTIL_CLASSES=$(subst .java,.class,$(UTIL_SOURCES)) +JAVA_CLASSES+=$(UTIL_CLASSES) + PITYTEST_DIR=../../../pitytest ifdef ENGINE_LIB_PATH diff --git a/test/java/foundation/pEp/jniadapter/test/basic/Makefile b/test/java/foundation/pEp/jniadapter/test/basic/Makefile index 1366beb..19da4db 100644 --- a/test/java/foundation/pEp/jniadapter/test/basic/Makefile +++ b/test/java/foundation/pEp/jniadapter/test/basic/Makefile @@ -3,11 +3,7 @@ include ../Makefile.conf TEST_UNIT_NAME=basic -JAVA_CLASSES = \ - TestMain.class \ - ../utils/AdapterBaseTestContext.class \ - ../utils/AdapterTestUtils.class \ - ../utils/TestCallbacks.class +JAVA_CLASSES+=TestMain.class .PHONY: pitytest compile run test clean diff --git a/test/java/foundation/pEp/jniadapter/test/basic/TestMain.java b/test/java/foundation/pEp/jniadapter/test/basic/TestMain.java index 162c81f..da1e8b0 100644 --- a/test/java/foundation/pEp/jniadapter/test/basic/TestMain.java +++ b/test/java/foundation/pEp/jniadapter/test/basic/TestMain.java @@ -3,7 +3,7 @@ package foundation.pEp.jniadapter.test.basic; import foundation.pEp.jniadapter.Identity; import foundation.pEp.jniadapter.Message; import foundation.pEp.jniadapter.decrypt_message_Return; -import foundation.pEp.jniadapter.test.utils.AdapterBaseTestContext; +import foundation.pEp.jniadapter.test.utils.CTXBase; import foundation.pEp.jniadapter.test.utils.AdapterTestUtils; import foundation.pEp.pitytest.TestSuite; import foundation.pEp.pitytest.TestUnit; @@ -12,7 +12,7 @@ import java.util.Vector; import static foundation.pEp.pitytest.TestLogger.log; -class BasicTestContext extends AdapterBaseTestContext { +class BasicTestContext extends CTXBase { Message enc; decrypt_message_Return result; diff --git a/test/java/foundation/pEp/jniadapter/test/jni100/Makefile b/test/java/foundation/pEp/jniadapter/test/jni100/Makefile index abc46e1..d50a2c0 100644 --- a/test/java/foundation/pEp/jniadapter/test/jni100/Makefile +++ b/test/java/foundation/pEp/jniadapter/test/jni100/Makefile @@ -3,10 +3,8 @@ include ../Makefile.conf TEST_UNIT_NAME=jni100 -JAVA_CLASSES = \ - TestMain.class \ - ../utils/AdapterTestUtils.class \ - ../utils/TestCallbacks.class +JAVA_CLASSES+= \ + TestMain.class .PHONY: pitytest compile run test clean diff --git a/test/java/foundation/pEp/jniadapter/test/jni100/TestMain.java b/test/java/foundation/pEp/jniadapter/test/jni100/TestMain.java index 030a771..c377c5a 100644 --- a/test/java/foundation/pEp/jniadapter/test/jni100/TestMain.java +++ b/test/java/foundation/pEp/jniadapter/test/jni100/TestMain.java @@ -8,7 +8,7 @@ import java.util.Vector; class TestMain { public static void main(String[] args) throws Exception { - new TestUnit("JNI-100",new AdapterBaseTestContext() , ctx -> { + new TestUnit("JNI-100",new CTXBase() , ctx -> { TestCallbacks cb = new TestCallbacks(); ctx.engine.setMessageToSendCallback(cb); diff --git a/test/java/foundation/pEp/jniadapter/test/jni111/Makefile b/test/java/foundation/pEp/jniadapter/test/jni111/Makefile index c2d0437..7007bde 100644 --- a/test/java/foundation/pEp/jniadapter/test/jni111/Makefile +++ b/test/java/foundation/pEp/jniadapter/test/jni111/Makefile @@ -3,11 +3,8 @@ include ../Makefile.conf TEST_UNIT_NAME=jni111 -JAVA_CLASSES = \ - TestAlice.class \ - ../utils/AdapterBaseTestContext.class \ - ../utils/AdapterTestUtils.class \ - ../utils/TestCallbacks.class +JAVA_CLASSES+= \ + TestAlice.class .PHONY: pitytest compile alice test clean diff --git a/test/java/foundation/pEp/jniadapter/test/jni111/TestAlice.java b/test/java/foundation/pEp/jniadapter/test/jni111/TestAlice.java index 2588c70..e0f94e1 100644 --- a/test/java/foundation/pEp/jniadapter/test/jni111/TestAlice.java +++ b/test/java/foundation/pEp/jniadapter/test/jni111/TestAlice.java @@ -5,7 +5,7 @@ import foundation.pEp.jniadapter.Message; import foundation.pEp.jniadapter.exceptions.pEpException; import foundation.pEp.jniadapter.exceptions.pEpPassphraseRequired; import foundation.pEp.jniadapter.exceptions.pEpWrongPassphrase; -import foundation.pEp.jniadapter.test.utils.AdapterBaseTestContext; +import foundation.pEp.jniadapter.test.utils.CTXBase; import foundation.pEp.jniadapter.test.utils.AdapterTestUtils; import foundation.pEp.pitytest.TestSuite; import foundation.pEp.pitytest.TestUnit; @@ -18,7 +18,7 @@ import static foundation.pEp.pitytest.TestLogger.log; // https://pep.foundation/jira/browse/JNI-111 -class JNI111TestContext extends AdapterBaseTestContext { +class JNI111TestContext extends CTXBase { @Override public JNI111TestContext init() throws Throwable { super.init(); @@ -34,16 +34,16 @@ class TestAlice { TestSuite.getDefault().setVerbose(false); TestSuite.getDefault().setTestColor(TestUtils.TermColor.GREEN); - AdapterBaseTestContext jni111Ctx = new JNI111TestContext(); + CTXBase jni111Ctx = new JNI111TestContext(); - new TestUnit("importKey()", jni111Ctx, ctx -> { + new TestUnit("importKey()", jni111Ctx, ctx -> { assert ctx.alice == null: "Alice is not null"; ctx.alice = ctx.engine.importKey(ctx.keyAliceSecPassphrase).get(0); log(AdapterTestUtils.identityToString(ctx.alice, true)); assert ctx.alice != null: "Keyimport failed"; }); - new TestUnit("setOwnKey()", jni111Ctx, ctx -> { + new TestUnit("setOwnKey()", jni111Ctx, ctx -> { ctx.alice.user_id = "23"; ctx.alice = ctx.engine.setOwnKey(ctx.alice, ctx.alice.fpr); log(AdapterTestUtils.identityToString(ctx.alice, true)); @@ -51,7 +51,7 @@ class TestAlice { assert ctx.alice.comm_type == CommType.PEP_ct_pEp; }); - new TestUnit("encrypt_message() -> pEpPassphraseRequired ", jni111Ctx, ctx -> { + new TestUnit("encrypt_message() -> pEpPassphraseRequired ", jni111Ctx, ctx -> { try { Message enc = ctx.engine.encrypt_message(ctx.msgAliceToAlice, new Vector<>(), Message.EncFormat.PEP); } catch (pEpException e) { @@ -61,11 +61,11 @@ class TestAlice { assert false:"encrypt_message() should have failed"; }); - new TestUnit("config_passphrase() wrong", jni111Ctx, ctx -> { + new TestUnit("config_passphrase() wrong", jni111Ctx, ctx -> { ctx.engine.config_passphrase("WRONG PASSPHRASE"); }); - new TestUnit("encrypt_message() -> pEpWrongPassphrase ", jni111Ctx, ctx -> { + new TestUnit("encrypt_message() -> pEpWrongPassphrase ", jni111Ctx, ctx -> { try { Message enc = ctx.engine.encrypt_message(ctx.msgAliceToAlice, new Vector<>(), Message.EncFormat.PEP); } catch (pEpException e) { @@ -75,11 +75,11 @@ class TestAlice { assert false:"encrypt_message() should have failed"; }); - new TestUnit("config_passphrase() correct", jni111Ctx, ctx -> { + new TestUnit("config_passphrase() correct", jni111Ctx, ctx -> { ctx.engine.config_passphrase("passphrase_alice"); }); - new TestUnit("encrypt_message() -> success", jni111Ctx, ctx -> { + new TestUnit("encrypt_message() -> success", jni111Ctx, ctx -> { assert ctx.msgAliceToAlice.getEncFormat() == Message.EncFormat.None : "Orig msg not plain"; Message enc = ctx.engine.encrypt_message(ctx.msgAliceToAlice, new Vector<>(), Message.EncFormat.PEP); assert enc.getEncFormat() == Message.EncFormat.PGPMIME :"Message not encrypted"; diff --git a/test/java/foundation/pEp/jniadapter/test/jni114/Makefile b/test/java/foundation/pEp/jniadapter/test/jni114/Makefile index 36d6ce8..8b7bbd0 100644 --- a/test/java/foundation/pEp/jniadapter/test/jni114/Makefile +++ b/test/java/foundation/pEp/jniadapter/test/jni114/Makefile @@ -3,11 +3,8 @@ include ../Makefile.conf TEST_UNIT_NAME=jni114 -JAVA_CLASSES = \ - TestAlice.class \ - ../utils/AdapterBaseTestContext.class \ - ../utils/AdapterTestUtils.class \ - ../utils/TestCallbacks.class +JAVA_CLASSES+= \ + TestAlice.class .PHONY: pitytest compile alice test clean diff --git a/test/java/foundation/pEp/jniadapter/test/jni114/TestAlice.java b/test/java/foundation/pEp/jniadapter/test/jni114/TestAlice.java index 1dfa62f..3965734 100644 --- a/test/java/foundation/pEp/jniadapter/test/jni114/TestAlice.java +++ b/test/java/foundation/pEp/jniadapter/test/jni114/TestAlice.java @@ -21,8 +21,8 @@ class TestAlice { TestSuite.getDefault().setVerbose(true); TestSuite.getDefault().setTestColor(TestUtils.TermColor.GREEN); - AdapterBaseTestContext jni114Ctx = new AdapterBaseTestContext(); - new TestUnit("ImportKey/SetOwnKey", jni114Ctx, ctx -> { + CTXBase jni114Ctx = new CTXBase(); + new TestUnit("ImportKey/SetOwnKey", jni114Ctx, ctx -> { // ImportKey and setOwnKey (with passphrase, of course) ctx.alice = ctx.engine.importKey(ctx.keyAliceSecPassphrase).get(0); log(AdapterTestUtils.identityToString(ctx.alice, true)); @@ -34,7 +34,7 @@ class TestAlice { }); - new TestUnit("no callback / encrypt fails nonblocking", jni114Ctx, ctx -> { + new TestUnit("no callback / encrypt fails nonblocking", jni114Ctx, ctx -> { ctx.alice = ctx.engine.myself(ctx.alice); try { Message enc = ctx.engine.encrypt_message(ctx.msgAliceToAlice, new Vector<>(), Message.EncFormat.PEP); @@ -46,7 +46,7 @@ class TestAlice { }); - new TestUnit("use callback for encrypt", jni114Ctx, ctx -> { + new TestUnit("use callback for encrypt", jni114Ctx, ctx -> { // Register callback passphraseRequired() ctx.engine.setPassphraseRequiredCallback(new Sync.PassphraseRequiredCallback() { @Override diff --git a/test/java/foundation/pEp/jniadapter/test/jni115/Makefile b/test/java/foundation/pEp/jniadapter/test/jni115/Makefile index 3ae14c6..add8573 100644 --- a/test/java/foundation/pEp/jniadapter/test/jni115/Makefile +++ b/test/java/foundation/pEp/jniadapter/test/jni115/Makefile @@ -3,11 +3,8 @@ include ../Makefile.conf TEST_UNIT_NAME=jni115 -JAVA_CLASSES = \ - TestAlice.class \ - ../utils/AdapterBaseTestContext.class \ - ../utils/AdapterTestUtils.class \ - ../utils/TestCallbacks.class +JAVA_CLASSES+= \ + TestAlice.class .PHONY: pitytest compile alice test clean diff --git a/test/java/foundation/pEp/jniadapter/test/jni115/TestAlice.java b/test/java/foundation/pEp/jniadapter/test/jni115/TestAlice.java index 446f76a..cfe0c32 100644 --- a/test/java/foundation/pEp/jniadapter/test/jni115/TestAlice.java +++ b/test/java/foundation/pEp/jniadapter/test/jni115/TestAlice.java @@ -1,7 +1,7 @@ package foundation.pEp.jniadapter.test.jni115; import foundation.pEp.jniadapter.Message; -import foundation.pEp.jniadapter.test.utils.AdapterBaseTestContext; +import foundation.pEp.jniadapter.test.utils.CTXBase; import foundation.pEp.jniadapter.test.utils.AdapterTestUtils; import foundation.pEp.pitytest.TestSuite; import foundation.pEp.pitytest.TestUnit; @@ -13,7 +13,7 @@ import java.util.List; import static foundation.pEp.pitytest.TestLogger.log; import static foundation.pEp.pitytest.TestLogger.logRaw; -class Jni115TestContext extends AdapterBaseTestContext { +class Jni115TestContext extends CTXBase { public int messagesToBobCount = 10; public List messagesToBobSmall; public List messagesToBobBig; diff --git a/test/java/foundation/pEp/jniadapter/test/jni117/Makefile b/test/java/foundation/pEp/jniadapter/test/jni117/Makefile index 8c8748e..eaf8506 100644 --- a/test/java/foundation/pEp/jniadapter/test/jni117/Makefile +++ b/test/java/foundation/pEp/jniadapter/test/jni117/Makefile @@ -3,11 +3,8 @@ include ../Makefile.conf TEST_UNIT_NAME=jni117 -JAVA_CLASSES = \ - TestAlice.class \ - ../utils/AdapterBaseTestContext.class \ - ../utils/AdapterTestUtils.class \ - ../utils/TestCallbacks.class +JAVA_CLASSES+= \ + TestAlice.class .PHONY: pitytest compile alice test clean diff --git a/test/java/foundation/pEp/jniadapter/test/jni117/TestAlice.java b/test/java/foundation/pEp/jniadapter/test/jni117/TestAlice.java index 597eb74..4484e54 100644 --- a/test/java/foundation/pEp/jniadapter/test/jni117/TestAlice.java +++ b/test/java/foundation/pEp/jniadapter/test/jni117/TestAlice.java @@ -1,5 +1,5 @@ package foundation.pEp.jniadapter.test.jni117; -import foundation.pEp.jniadapter.test.utils.AdapterBaseTestContext; +import foundation.pEp.jniadapter.test.utils.CTXBase; import foundation.pEp.pitytest.TestSuite; import foundation.pEp.pitytest.TestUnit; import foundation.pEp.pitytest.utils.TestUtils; @@ -18,7 +18,7 @@ class TestAlice { TestSuite.getDefault().setVerbose(true); TestSuite.getDefault().setTestColor(TestUtils.TermColor.GREEN); - new TestUnit("Test Alice",new AdapterBaseTestContext() , ctx -> { + new TestUnit("Test Alice",new CTXBase() , ctx -> { ctx.alice = ctx.engine.myself(ctx.alice); byte[] keydata = ctx.engine.export_key(ctx.alice.fpr); String keydataStr = new String(keydata); diff --git a/test/java/foundation/pEp/jniadapter/test/jni118/Makefile b/test/java/foundation/pEp/jniadapter/test/jni118/Makefile index d9d921c..8ef957a 100644 --- a/test/java/foundation/pEp/jniadapter/test/jni118/Makefile +++ b/test/java/foundation/pEp/jniadapter/test/jni118/Makefile @@ -3,11 +3,8 @@ include ../Makefile.conf TEST_UNIT_NAME=jni118 -JAVA_CLASSES = \ - TestAlice.class \ - ../utils/AdapterBaseTestContext.class \ - ../utils/AdapterTestUtils.class \ - ../utils/TestCallbacks.class +JAVA_CLASSES+= \ + TestAlice.class .PHONY: pitytest compile alice test clean diff --git a/test/java/foundation/pEp/jniadapter/test/jni118/TestAlice.java b/test/java/foundation/pEp/jniadapter/test/jni118/TestAlice.java index 7100605..fd6ff7b 100644 --- a/test/java/foundation/pEp/jniadapter/test/jni118/TestAlice.java +++ b/test/java/foundation/pEp/jniadapter/test/jni118/TestAlice.java @@ -36,7 +36,7 @@ import java.util.Vector; -class JNI1118Context extends AdapterBaseTestContext { +class JNI1118Context extends CTXBase { public Message msgToBobEncrypted; public Message msgToBobDecrypted; public decrypt_message_Return msgToBobDecryptResult; diff --git a/test/java/foundation/pEp/jniadapter/test/jni119/Makefile b/test/java/foundation/pEp/jniadapter/test/jni119/Makefile index 329571b..da40a7a 100644 --- a/test/java/foundation/pEp/jniadapter/test/jni119/Makefile +++ b/test/java/foundation/pEp/jniadapter/test/jni119/Makefile @@ -3,11 +3,8 @@ include ../Makefile.conf TEST_UNIT_NAME=jni119 -JAVA_CLASSES = \ - TestAlice.class \ - ../utils/AdapterBaseTestContext.class \ - ../utils/AdapterTestUtils.class \ - ../utils/TestCallbacks.class +JAVA_CLASSES+= \ + TestAlice.class .PHONY: pitytest compile alice test clean diff --git a/test/java/foundation/pEp/jniadapter/test/jni119/TestAlice.java b/test/java/foundation/pEp/jniadapter/test/jni119/TestAlice.java index 304732b..4640345 100644 --- a/test/java/foundation/pEp/jniadapter/test/jni119/TestAlice.java +++ b/test/java/foundation/pEp/jniadapter/test/jni119/TestAlice.java @@ -1,7 +1,7 @@ package foundation.pEp.jniadapter.test.jni119; import foundation.pEp.jniadapter.Identity; -import foundation.pEp.jniadapter.test.utils.AdapterBaseTestContext; +import foundation.pEp.jniadapter.test.utils.CTXBase; import foundation.pEp.pitytest.TestSuite; import foundation.pEp.pitytest.TestUnit; import foundation.pEp.pitytest.utils.TestUtils; @@ -14,12 +14,12 @@ class TestAlice { TestSuite.getDefault().setVerbose(true); TestSuite.getDefault().setTestColor(TestUtils.TermColor.GREEN); - new TestUnit("enter_device_group() no exception with no identities", new AdapterBaseTestContext(), ctx -> { + new TestUnit("enter_device_group() no exception with no identities", new CTXBase(), ctx -> { ctx.alice = ctx.engine.myself(ctx.alice); ctx.engine.enter_device_group(new Vector()); }); - new TestUnit("enter_device_group() no exception with 2 identities", new AdapterBaseTestContext(), ctx -> { + new TestUnit("enter_device_group() no exception with 2 identities", new CTXBase(), ctx -> { ctx.alice = ctx.engine.myself(ctx.alice); ctx.bob = ctx.engine.myself(ctx.bob); diff --git a/test/java/foundation/pEp/jniadapter/test/jni125/Makefile b/test/java/foundation/pEp/jniadapter/test/jni125/Makefile index e97b00d..cb7ee18 100644 --- a/test/java/foundation/pEp/jniadapter/test/jni125/Makefile +++ b/test/java/foundation/pEp/jniadapter/test/jni125/Makefile @@ -3,11 +3,8 @@ include ../Makefile.conf TEST_UNIT_NAME=jni125 -JAVA_CLASSES = \ - TestAlice.class \ - ../utils/AdapterBaseTestContext.class \ - ../utils/AdapterTestUtils.class \ - ../utils/TestCallbacks.class +JAVA_CLASSES+= \ + TestAlice.class .PHONY: pitytest compile alice test clean diff --git a/test/java/foundation/pEp/jniadapter/test/jni125/TestAlice.java b/test/java/foundation/pEp/jniadapter/test/jni125/TestAlice.java index befe6b3..0c2eb6b 100644 --- a/test/java/foundation/pEp/jniadapter/test/jni125/TestAlice.java +++ b/test/java/foundation/pEp/jniadapter/test/jni125/TestAlice.java @@ -1,7 +1,7 @@ package foundation.pEp.jniadapter.test.jni125; import foundation.pEp.jniadapter.Message; -import foundation.pEp.jniadapter.test.utils.AdapterBaseTestContext; +import foundation.pEp.jniadapter.test.utils.CTXBase; import foundation.pEp.pitytest.TestSuite; import foundation.pEp.pitytest.TestUnit; import foundation.pEp.pitytest.utils.TestUtils; @@ -11,7 +11,7 @@ class TestAlice { TestSuite.getDefault().setVerbose(false); TestSuite.getDefault().setTestColor(TestUtils.TermColor.GREEN); - new TestUnit("enum Message.EncFormat verify .value", new AdapterBaseTestContext(), ctx -> { + new TestUnit("enum Message.EncFormat verify .value", new CTXBase(), ctx -> { //TODO: This is stupid, we need a PityAssert() assert Message.EncFormat.None.value == 0 : "Message.EncFormat.None == " + Message.EncFormat.None.value + "; expected " + 0; assert Message.EncFormat.Pieces.value == 1 : "Message.Pieces.None == " + Message.EncFormat.Pieces.value + "; expected " + 1; @@ -24,7 +24,7 @@ class TestAlice { assert Message.EncFormat.PEPEncAuto.value == 255 : "Message.PEPEncAuto.None == " + Message.EncFormat.PEPEncAuto.value + "; expected " + 255; }); - new TestUnit("enum Message.EncFormat verify getByInt(0)", new AdapterBaseTestContext(), ctx -> { + new TestUnit("enum Message.EncFormat verify getByInt(0)", new CTXBase(), ctx -> { assert Message.EncFormat.getByInt(0) == Message.EncFormat.None; assert Message.EncFormat.getByInt(1) == Message.EncFormat.Inline; assert Message.EncFormat.getByInt(2) == Message.EncFormat.SMIME; diff --git a/test/java/foundation/pEp/jniadapter/test/jni126/Makefile b/test/java/foundation/pEp/jniadapter/test/jni126/Makefile index d550140..264899b 100644 --- a/test/java/foundation/pEp/jniadapter/test/jni126/Makefile +++ b/test/java/foundation/pEp/jniadapter/test/jni126/Makefile @@ -3,11 +3,8 @@ include ../Makefile.conf TEST_UNIT_NAME=jni126 -JAVA_CLASSES = \ - TestAlice.class \ - ../utils/AdapterBaseTestContext.class \ - ../utils/AdapterTestUtils.class \ - ../utils/TestCallbacks.class +JAVA_CLASSES+= \ + TestAlice.class .PHONY: pitytest compile alice test clean diff --git a/test/java/foundation/pEp/jniadapter/test/jni126/TestAlice.java b/test/java/foundation/pEp/jniadapter/test/jni126/TestAlice.java index 3f54317..6c14cb2 100644 --- a/test/java/foundation/pEp/jniadapter/test/jni126/TestAlice.java +++ b/test/java/foundation/pEp/jniadapter/test/jni126/TestAlice.java @@ -1,7 +1,7 @@ package foundation.pEp.jniadapter.test.jni126; import foundation.pEp.jniadapter.*; -import foundation.pEp.jniadapter.test.utils.AdapterBaseTestContext; +import foundation.pEp.jniadapter.test.utils.CTXBase; import foundation.pEp.pitytest.TestSuite; import foundation.pEp.pitytest.TestUnit; import foundation.pEp.pitytest.utils.TestUtils; @@ -9,9 +9,9 @@ import foundation.pEp.pitytest.utils.TestUtils; import static foundation.pEp.pitytest.TestLogger.*; import static foundation.pEp.pitytest.utils.TestUtils.*; -class Jni126TestContext extends AdapterBaseTestContext { +class Jni126TestContext extends CTXBase { @Override - public AdapterBaseTestContext init() throws Throwable { + public CTXBase init() throws Throwable { super.init(); alice = engine.importKey(keyAliceSecPassphrase).get(0); @@ -41,9 +41,9 @@ class TestAlice { TestSuite.getDefault().setVerbose(true); TestSuite.getDefault().setTestColor(TestUtils.TermColor.GREEN); - AdapterBaseTestContext jni126Ctx = new Jni126TestContext(); + CTXBase jni126Ctx = new Jni126TestContext(); - new TestUnit("startSync()/stopSync()", jni126Ctx, ctx -> { + new TestUnit("startSync()/stopSync()", jni126Ctx, ctx -> { for(int reps = 0; reps < 3; reps++) { ctx.engine.startSync(); for (int i = 0; i < 10; i++) { diff --git a/test/java/foundation/pEp/jniadapter/test/jni134/Makefile b/test/java/foundation/pEp/jniadapter/test/jni134/Makefile index 5fa310c..6dd455f 100644 --- a/test/java/foundation/pEp/jniadapter/test/jni134/Makefile +++ b/test/java/foundation/pEp/jniadapter/test/jni134/Makefile @@ -3,11 +3,8 @@ include ../Makefile.conf TEST_UNIT_NAME=jni134 -JAVA_CLASSES = \ - TestAlice.class \ - ../utils/AdapterBaseTestContext.class \ - ../utils/AdapterTestUtils.class \ - ../utils/TestCallbacks.class +JAVA_CLASSES+= \ + TestAlice.class .PHONY: pitytest compile alice test clean diff --git a/test/java/foundation/pEp/jniadapter/test/jni134/TestAlice.java b/test/java/foundation/pEp/jniadapter/test/jni134/TestAlice.java index 7e47440..6fdbb18 100644 --- a/test/java/foundation/pEp/jniadapter/test/jni134/TestAlice.java +++ b/test/java/foundation/pEp/jniadapter/test/jni134/TestAlice.java @@ -4,7 +4,7 @@ import foundation.pEp.jniadapter.Blob; import foundation.pEp.jniadapter.Identity; import foundation.pEp.jniadapter.Message; import foundation.pEp.jniadapter.Pair; -import foundation.pEp.jniadapter.test.utils.AdapterBaseTestContext; +import foundation.pEp.jniadapter.test.utils.CTXBase; import foundation.pEp.jniadapter.test.utils.AdapterTestUtils; import foundation.pEp.pitytest.TestSuite; import foundation.pEp.pitytest.TestUnit; @@ -16,9 +16,9 @@ import java.util.Vector; import static foundation.pEp.pitytest.TestLogger.log; -class Jni134TestContext extends AdapterBaseTestContext { +class Jni134TestContext extends CTXBase { @Override - public AdapterBaseTestContext init() throws Throwable { + public CTXBase init() throws Throwable { super.init(); return this; } @@ -29,9 +29,9 @@ class TestAlice { TestSuite.getDefault().setVerbose(true); TestSuite.getDefault().setTestColor(TestUtils.TermColor.GREEN); - AdapterBaseTestContext jni134Ctx = new Jni134TestContext(); + CTXBase jni134Ctx = new Jni134TestContext(); - new TestUnit("setDir() == getDir() ", new Jni134TestContext(), ctx -> { + new TestUnit("setDir() == getDir() ", new Jni134TestContext(), ctx -> { Message msg = new Message(); Message.Direction inVal = ctx.msgDirOutgoing; msg.setDir(inVal); @@ -39,7 +39,7 @@ class TestAlice { assert outVal == inVal : "\nreturned '" + outVal + "' instead of '" + inVal + "'"; }); - new TestUnit("setId() == getId() ", new Jni134TestContext(), ctx -> { + new TestUnit("setId() == getId() ", new Jni134TestContext(), ctx -> { Message msg = new Message(); String inVal = "23"; msg.setId(inVal); @@ -47,7 +47,7 @@ class TestAlice { assert outVal.equals(inVal) : "\nreturned '" + outVal + "' instead of '" + inVal + "'"; }); - new TestUnit("setShortmsg() == getShortmsg() ", new Jni134TestContext(), ctx -> { + new TestUnit("setShortmsg() == getShortmsg() ", new Jni134TestContext(), ctx -> { Message msg = new Message(); String inVal = "23"; msg.setShortmsg(inVal); @@ -55,7 +55,7 @@ class TestAlice { assert outVal.equals(inVal) : "\nreturned '" + outVal + "' instead of '" + inVal + "'"; }); - new TestUnit("setLongmsg() == getLongmsg() ", new Jni134TestContext(), ctx -> { + new TestUnit("setLongmsg() == getLongmsg() ", new Jni134TestContext(), ctx -> { Message msg = new Message(); String inVal = "23"; msg.setLongmsg(inVal); @@ -63,7 +63,7 @@ class TestAlice { assert outVal.equals(inVal) : "\nreturned '" + outVal + "' instead of '" + inVal + "'"; }); - new TestUnit("setLongmsgFormatted() == getLongmsgFormatted() ", new Jni134TestContext(), ctx -> { + new TestUnit("setLongmsgFormatted() == getLongmsgFormatted() ", new Jni134TestContext(), ctx -> { Message msg = new Message(); String inVal = "23"; msg.setLongmsgFormatted(inVal); @@ -72,12 +72,12 @@ class TestAlice { }); // TODO: use .equals() - new TestUnit("setAttachments() == getAttachments() ", new Jni134TestContext(), ctx -> { + new TestUnit("setAttachments() == getAttachments() ", new Jni134TestContext(), ctx -> { Message msg = new Message(); - Vector inVal = ctx.attachments; + Vector inVal = ctx.attachmentList.getAttachments(); msg.setAttachments(inVal); Vector outVal = msg.getAttachments(); - for (int i = 0; i < ctx.attachmentsLen; i++) { + for (int i = 0; i < ctx.attachmentList.getCount(); i++) { Blob inElem = inVal.get(i); Blob outElem = outVal.get(i); assert inElem == outElem : "\nreturned '" + outElem + "' instead of '" + inElem + "'"; @@ -85,7 +85,7 @@ class TestAlice { }); // TODO: Date precision is truncated to seconds in the message struct - new TestUnit("setSent() == getSent() ", new Jni134TestContext(), ctx -> { + new TestUnit("setSent() == getSent() ", new Jni134TestContext(), ctx -> { Message msg = new Message(); Date inVal = new Date(); msg.setSent(inVal); @@ -97,7 +97,7 @@ class TestAlice { }); // TODO: Date precision is truncated to seconds in the message struct - new TestUnit("setRecv() == getRecv() ", new Jni134TestContext(), ctx -> { + new TestUnit("setRecv() == getRecv() ", new Jni134TestContext(), ctx -> { Message msg = new Message(); Date inVal = new Date(); msg.setRecv(inVal); @@ -106,7 +106,7 @@ class TestAlice { }); // TODO: use .equals() - new TestUnit("setFrom() == getFrom() ", new Jni134TestContext(), ctx -> { + new TestUnit("setFrom() == getFrom() ", new Jni134TestContext(), ctx -> { Message msg = new Message(); Identity inVal = ctx.alice; msg.setFrom(inVal); @@ -115,7 +115,7 @@ class TestAlice { }); // TODO: use .equals() - new TestUnit("setTo() == getTo() ", new Jni134TestContext(), ctx -> { + new TestUnit("setTo() == getTo() ", new Jni134TestContext(), ctx -> { Message msg = new Message(); Vector inVal = new Vector(); inVal.add(ctx.alice); @@ -130,7 +130,7 @@ class TestAlice { }); // TODO: use .equals() - new TestUnit("setRecvBy() == getRecvBy() ", new Jni134TestContext(), ctx -> { + new TestUnit("setRecvBy() == getRecvBy() ", new Jni134TestContext(), ctx -> { Message msg = new Message(); Identity inVal = ctx.alice; msg.setRecvBy(inVal); @@ -139,7 +139,7 @@ class TestAlice { }); // TODO: use .equals() - new TestUnit("setCc() == getCc() ", new Jni134TestContext(), ctx -> { + new TestUnit("setCc() == getCc() ", new Jni134TestContext(), ctx -> { Message msg = new Message(); Vector inVal = new Vector(); inVal.add(ctx.alice); @@ -154,7 +154,7 @@ class TestAlice { }); // TODO: use .equals() - new TestUnit("setBcc() == getBcc() ", new Jni134TestContext(), ctx -> { + new TestUnit("setBcc() == getBcc() ", new Jni134TestContext(), ctx -> { Message msg = new Message(); Vector inVal = new Vector(); inVal.add(ctx.alice); @@ -169,7 +169,7 @@ class TestAlice { }); // TODO: use .equals() - new TestUnit("setReplyTo() == getReplyTo() ", new Jni134TestContext(), ctx -> { + new TestUnit("setReplyTo() == getReplyTo() ", new Jni134TestContext(), ctx -> { Message msg = new Message(); Vector inVal = new Vector(); inVal.add(ctx.alice); @@ -184,7 +184,7 @@ class TestAlice { }); // TODO: use .equals() - new TestUnit("setInReplyTo() == getInReplyTo() ", new Jni134TestContext(), ctx -> { + new TestUnit("setInReplyTo() == getInReplyTo() ", new Jni134TestContext(), ctx -> { Message msg = new Message(); Vector inVal = new Vector(); inVal.add("pEp-auto-consume@pEp.foundation"); @@ -199,7 +199,7 @@ class TestAlice { }); // TODO: use .equals() - new TestUnit("setReferences() == getReferences() ", new Jni134TestContext(), ctx -> { + new TestUnit("setReferences() == getReferences() ", new Jni134TestContext(), ctx -> { Message msg = new Message(); Vector inVal = new Vector(); inVal.add("pEp-auto-consume@pEp.foundation"); @@ -214,7 +214,7 @@ class TestAlice { }); // TODO: use .equals() - new TestUnit("setKeywords() == getKeywords() ", new Jni134TestContext(), ctx -> { + new TestUnit("setKeywords() == getKeywords() ", new Jni134TestContext(), ctx -> { Message msg = new Message(); Vector inVal = new Vector(); inVal.add("pEp-auto-consume@pEp.foundation"); @@ -229,7 +229,7 @@ class TestAlice { }); // TODO: use .equals() - new TestUnit("setComments() == getComments() ", new Jni134TestContext(), ctx -> { + new TestUnit("setComments() == getComments() ", new Jni134TestContext(), ctx -> { Message msg = new Message(); String inVal = "pEp-auto-consume@pEp.foundation"; msg.setComments(inVal); @@ -237,7 +237,7 @@ class TestAlice { assert outVal.equals(inVal) : "\nreturned:\n '" + outVal + "'\nexpected:\n '" + inVal + "'"; }); - new TestUnit("setOptFields() == getOptFields() ", new Jni134TestContext(), ctx -> { + new TestUnit("setOptFields() == getOptFields() ", new Jni134TestContext(), ctx -> { Message msg = new Message(); ArrayList> inVal = new ArrayList<>(); inVal.add(new Pair<>("Received", "in time")); @@ -247,7 +247,7 @@ class TestAlice { assert AdapterTestUtils.optFieldsEqual(inVal, outVal) : "\nreturned:\n '" + outVal + "'\nexpected:\n '" + inVal + "'"; }); - new TestUnit("setEncFormat() == getEncFormat() ", new Jni134TestContext(), ctx -> { + new TestUnit("setEncFormat() == getEncFormat() ", new Jni134TestContext(), ctx -> { Message msg = new Message(); Message.EncFormat inVal = Message.EncFormat.PEP; msg.setEncFormat(inVal); diff --git a/test/java/foundation/pEp/jniadapter/test/jni135/Makefile b/test/java/foundation/pEp/jniadapter/test/jni135/Makefile index 2298b54..10868fc 100644 --- a/test/java/foundation/pEp/jniadapter/test/jni135/Makefile +++ b/test/java/foundation/pEp/jniadapter/test/jni135/Makefile @@ -3,11 +3,8 @@ include ../Makefile.conf TEST_UNIT_NAME=jni135 -JAVA_CLASSES = \ - TestAlice.class \ - ../utils/AdapterBaseTestContext.class \ - ../utils/AdapterTestUtils.class \ - ../utils/TestCallbacks.class +JAVA_CLASSES+= \ + TestAlice.class .PHONY: pitytest compile alice test clean diff --git a/test/java/foundation/pEp/jniadapter/test/jni135/TestAlice.java b/test/java/foundation/pEp/jniadapter/test/jni135/TestAlice.java index 950943d..8a367d6 100644 --- a/test/java/foundation/pEp/jniadapter/test/jni135/TestAlice.java +++ b/test/java/foundation/pEp/jniadapter/test/jni135/TestAlice.java @@ -4,7 +4,7 @@ import foundation.pEp.jniadapter.Blob; import foundation.pEp.jniadapter.Engine; import foundation.pEp.jniadapter.Message; import foundation.pEp.jniadapter.decrypt_message_Return; -import foundation.pEp.jniadapter.test.utils.AdapterBaseTestContext; +import foundation.pEp.jniadapter.test.utils.CTXBase; import foundation.pEp.jniadapter.test.utils.AdapterTestUtils; import foundation.pEp.pitytest.TestSuite; import foundation.pEp.pitytest.TestUnit; @@ -16,9 +16,9 @@ import java.util.Vector; import static foundation.pEp.pitytest.TestLogger.log; -class Jni135TestContext extends AdapterBaseTestContext { +class Jni135TestContext extends CTXBase { @Override - public AdapterBaseTestContext init() throws Throwable { + public CTXBase init() throws Throwable { super.init(); return this; } @@ -40,11 +40,11 @@ class TestAlice { // TestUtils.readKey(); TestSuite.getDefault().setVerbose(true); TestSuite.getDefault().setTestColor(TestUtils.TermColor.GREEN); - AdapterBaseTestContext jni135Ctx = new Jni135TestContext(); + CTXBase jni135Ctx = new Jni135TestContext(); Engine.setDebugLogEnabled(false); - new TestUnit("setDir() == getDir() ", new Jni135TestContext(), ctx -> { + new TestUnit("setDir() == getDir() ", new Jni135TestContext(), ctx -> { ctx.alice = ctx.engine.myself(ctx.alice); ctx.bob = ctx.engine.myself(ctx.bob); diff --git a/test/java/foundation/pEp/jniadapter/test/jni143/Makefile b/test/java/foundation/pEp/jniadapter/test/jni143/Makefile index 33e1e90..6d644b2 100644 --- a/test/java/foundation/pEp/jniadapter/test/jni143/Makefile +++ b/test/java/foundation/pEp/jniadapter/test/jni143/Makefile @@ -3,12 +3,8 @@ include ../Makefile.conf TEST_UNIT_NAME=jni143 -JAVA_CLASSES = \ - TestAlice.class \ - ../utils/AdapterBaseTestContext.class \ - ../utils/AdapterTestUtils.class \ - ../utils/DiffResult.class \ - ../utils/TestCallbacks.class +JAVA_CLASSES+= \ + TestAlice.class .PHONY: pitytest compile alice test clean diff --git a/test/java/foundation/pEp/jniadapter/test/jni143/TestAlice.java b/test/java/foundation/pEp/jniadapter/test/jni143/TestAlice.java index 82a5996..3d1b440 100644 --- a/test/java/foundation/pEp/jniadapter/test/jni143/TestAlice.java +++ b/test/java/foundation/pEp/jniadapter/test/jni143/TestAlice.java @@ -3,7 +3,7 @@ package foundation.pEp.jniadapter.test.jni143; import foundation.pEp.jniadapter.Blob; import foundation.pEp.jniadapter.Message; import foundation.pEp.jniadapter.decrypt_message_Return; -import foundation.pEp.jniadapter.test.utils.AdapterBaseTestContext; +import foundation.pEp.jniadapter.test.utils.CTXBase; import foundation.pEp.jniadapter.test.utils.AdapterTestUtils; import foundation.pEp.pitytest.TestSuite; import foundation.pEp.pitytest.TestUnit; @@ -26,9 +26,9 @@ assert dataIn == dataOut Logs the count of differing bytes. */ -class Jni143TestContext extends AdapterBaseTestContext { +class Jni143TestContext extends CTXBase { @Override - public AdapterBaseTestContext init() throws Throwable { + public CTXBase init() throws Throwable { super.init(); return this; } @@ -41,9 +41,9 @@ class TestAlice { TestSuite.getDefault().setVerbose(true); TestSuite.getDefault().setTestColor(TestUtils.TermColor.GREEN); // TestUtils.readKey(); - AdapterBaseTestContext jni143Ctx = new Jni143TestContext(); + CTXBase jni143Ctx = new Jni143TestContext(); - new TestUnit("Attachement sizes", new Jni143TestContext(), ctx -> { + new TestUnit("Attachement sizes", new Jni143TestContext(), ctx -> { ctx.alice = ctx.engine.myself(ctx.alice); ctx.bob = ctx.engine.myself(ctx.bob); diff --git a/test/java/foundation/pEp/jniadapter/test/jni88/Makefile b/test/java/foundation/pEp/jniadapter/test/jni88/Makefile index 5c70341..b9da79b 100644 --- a/test/java/foundation/pEp/jniadapter/test/jni88/Makefile +++ b/test/java/foundation/pEp/jniadapter/test/jni88/Makefile @@ -3,8 +3,7 @@ include ../Makefile.conf TEST_UNIT_NAME=jni88 -JAVA_CLASSES = \ - TestMain.class +JAVA_CLASSES=TestMain.class .PHONY: pitytest compile run test clean diff --git a/test/java/foundation/pEp/jniadapter/test/jni91/Makefile b/test/java/foundation/pEp/jniadapter/test/jni91/Makefile index e2f5fb6..4c128ce 100644 --- a/test/java/foundation/pEp/jniadapter/test/jni91/Makefile +++ b/test/java/foundation/pEp/jniadapter/test/jni91/Makefile @@ -3,8 +3,7 @@ include ../Makefile.conf TEST_UNIT_NAME=jni91 -JAVA_CLASSES = \ - TestMain.class +JAVA_CLASSES=TestMain.class .PHONY: pitytest compile run test clean diff --git a/test/java/foundation/pEp/jniadapter/test/jni92/Makefile b/test/java/foundation/pEp/jniadapter/test/jni92/Makefile index 745f3a3..126433e 100644 --- a/test/java/foundation/pEp/jniadapter/test/jni92/Makefile +++ b/test/java/foundation/pEp/jniadapter/test/jni92/Makefile @@ -3,9 +3,8 @@ include ../Makefile.conf TEST_UNIT_NAME=jni92 -JAVA_CLASSES = \ - TestMain.class \ - ../utils/AdapterTestUtils.class +JAVA_CLASSES+= \ + TestMain.class .PHONY: pitytest compile run test clean diff --git a/test/java/foundation/pEp/jniadapter/test/jni94/Makefile b/test/java/foundation/pEp/jniadapter/test/jni94/Makefile index 9c7363b..f9c5e3e 100644 --- a/test/java/foundation/pEp/jniadapter/test/jni94/Makefile +++ b/test/java/foundation/pEp/jniadapter/test/jni94/Makefile @@ -3,8 +3,8 @@ include ../Makefile.conf TEST_UNIT_NAME=jni94 -JAVA_CLASSES = \ - TestMain.class \ +JAVA_CLASSES+= \ + TestMain.class .PHONY: pitytest compile run test clean diff --git a/test/java/foundation/pEp/jniadapter/test/jni94/TestMain.java b/test/java/foundation/pEp/jniadapter/test/jni94/TestMain.java index 9e1115c..ff09f7d 100644 --- a/test/java/foundation/pEp/jniadapter/test/jni94/TestMain.java +++ b/test/java/foundation/pEp/jniadapter/test/jni94/TestMain.java @@ -1,7 +1,7 @@ package foundation.pEp.jniadapter.test.jni94; import foundation.pEp.pitytest.*; import foundation.pEp.jniadapter.*; -import foundation.pEp.jniadapter.test.utils.AdapterBaseTestContext; +import foundation.pEp.jniadapter.test.utils.CTXBase; /* This test tries to use the feature described in in JNI-94 @@ -13,7 +13,7 @@ https://pep.foundation/jira/browse/JNI-94 class TestMain { public static void main(String[] args) { - new TestUnit("JNI-94", new AdapterBaseTestContext(), ctx -> { + new TestUnit("JNI-94", new CTXBase(), ctx -> { TestLogger.logH2("Creating new Engine"); ctx.engine = new Engine(); Sync.DefaultCallback callbacks = new Sync.DefaultCallback(); diff --git a/test/java/foundation/pEp/jniadapter/test/jni96/Makefile b/test/java/foundation/pEp/jniadapter/test/jni96/Makefile index 14cc8f6..557768c 100644 --- a/test/java/foundation/pEp/jniadapter/test/jni96/Makefile +++ b/test/java/foundation/pEp/jniadapter/test/jni96/Makefile @@ -3,11 +3,8 @@ include ../Makefile.conf TEST_UNIT_NAME=jni96 -JAVA_CLASSES = \ - TestAlice.class \ - ../utils/AdapterBaseTestContext.class \ - ../utils/AdapterTestUtils.class \ - ../utils/TestCallbacks.class +JAVA_CLASSES+= \ + TestAlice.class .PHONY: pitytest compile alice test clean diff --git a/test/java/foundation/pEp/jniadapter/test/jni96/TestAlice.java b/test/java/foundation/pEp/jniadapter/test/jni96/TestAlice.java index f9ee818..1dddc5b 100644 --- a/test/java/foundation/pEp/jniadapter/test/jni96/TestAlice.java +++ b/test/java/foundation/pEp/jniadapter/test/jni96/TestAlice.java @@ -1,5 +1,4 @@ package foundation.pEp.jniadapter.test.jni96; -import static foundation.pEp.pitytest.TestLogger.*; import foundation.pEp.jniadapter.Identity; import foundation.pEp.pitytest.*; @@ -15,21 +14,21 @@ class TestAlice { TestSuite.getDefault().setVerbose(true); TestSuite.getDefault().setTestColor(TestUtils.TermColor.GREEN); - new TestUnit("import_key() 1 pub key",new AdapterBaseTestContext() , ctx -> { + new TestUnit("import_key() 1 pub key",new CTXBase() , ctx -> { Vector privKeys = null; privKeys = ctx.engine.importKey(ctx.keyAlicePub); log(AdapterTestUtils.identityListToString(privKeys, false)); assert privKeys.size() == 0: "pub key should not be in return"; }); - new TestUnit("import_key() 1 sec key",new AdapterBaseTestContext() , ctx -> { + new TestUnit("import_key() 1 sec key",new CTXBase() , ctx -> { Vector privKeys = null; privKeys = ctx.engine.importKey(ctx.keyAliceSec); log(AdapterTestUtils.identityListToString(privKeys, false)); assert privKeys.size() == 1: "imported sec key should be returned"; }); - new TestUnit("import_key() 2 pub keys",new AdapterBaseTestContext() , ctx -> { + new TestUnit("import_key() 2 pub keys",new CTXBase() , ctx -> { byte[] keys = concat(ctx.keyAlicePub, ctx.keyBobPub); Vector privKeys = null; @@ -38,7 +37,7 @@ class TestAlice { assert privKeys.size() == 0: "imported pub keys should not be returned"; }); - new TestUnit("import_key() 2 sec keys",new AdapterBaseTestContext() , ctx -> { + new TestUnit("import_key() 2 sec keys",new CTXBase() , ctx -> { byte[] keys = concat(ctx.keyAliceSec, ctx.keyBobSec); Vector privKeys = null; @@ -47,7 +46,7 @@ class TestAlice { assert privKeys.size() == 2: "imported sec keys should be returned"; }); - new TestUnit("import_key() 4 keys pub/sec",new AdapterBaseTestContext() , ctx -> { + new TestUnit("import_key() 4 keys pub/sec",new CTXBase() , ctx -> { byte[] keys = concat(ctx.keyAlicePub, concat(ctx.keyAliceSec, concat(ctx.keyBobPub, ctx.keyBobSec))); Vector privKeys = null; diff --git a/test/java/foundation/pEp/jniadapter/test/jni98/Makefile b/test/java/foundation/pEp/jniadapter/test/jni98/Makefile index 903216b..af36c57 100644 --- a/test/java/foundation/pEp/jniadapter/test/jni98/Makefile +++ b/test/java/foundation/pEp/jniadapter/test/jni98/Makefile @@ -3,9 +3,8 @@ include ../Makefile.conf TEST_UNIT_NAME=jni98 -JAVA_CLASSES = \ - TestMain.class \ - ../utils/AdapterTestUtils.class +JAVA_CLASSES+= \ + TestMain.class .PHONY: pitytest compile run test clean diff --git a/test/java/foundation/pEp/jniadapter/test/jni98/TestMain.java b/test/java/foundation/pEp/jniadapter/test/jni98/TestMain.java index 3d95d12..a44b67d 100644 --- a/test/java/foundation/pEp/jniadapter/test/jni98/TestMain.java +++ b/test/java/foundation/pEp/jniadapter/test/jni98/TestMain.java @@ -3,7 +3,7 @@ package foundation.pEp.jniadapter.test.jni98; import foundation.pEp.jniadapter.*; import foundation.pEp.jniadapter.Message; import foundation.pEp.pitytest.TestUnit; -import foundation.pEp.jniadapter.test.utils.AdapterBaseTestContext; +import foundation.pEp.jniadapter.test.utils.CTXBase; import java.util.Vector; @@ -28,7 +28,7 @@ Please see https://pep.foundation/jira/browse/JNI-98 for further discussion class TestMain { public static void main(String[] args) throws Exception { - new TestUnit("JNI-98 - Message.EncFormat.PEP", new AdapterBaseTestContext(), ctx -> { + new TestUnit("JNI-98 - Message.EncFormat.PEP", new CTXBase(), ctx -> { ctx.engine.importKey(ctx.keyBobPub); // Make msg1 by encrypting msgToBob logH2("Create target Message"); @@ -51,7 +51,7 @@ class TestMain { log("\n" + msgToString(result.dst, false)); }).run(); - new TestUnit("JNI-98 - Message.EncFormat.PEP_enc_inline_EA", new AdapterBaseTestContext(), ctx -> { + new TestUnit("JNI-98 - Message.EncFormat.PEP_enc_inline_EA", new CTXBase(), ctx -> { ctx.engine.importKey(ctx.keyBobPub); // Make msg1 by encrypting msgToBob logH2("Create target Message"); diff --git a/test/java/foundation/pEp/jniadapter/test/regression/Makefile b/test/java/foundation/pEp/jniadapter/test/regression/Makefile index 56226c4..8215ac9 100644 --- a/test/java/foundation/pEp/jniadapter/test/regression/Makefile +++ b/test/java/foundation/pEp/jniadapter/test/regression/Makefile @@ -3,9 +3,8 @@ include ../Makefile.conf TEST_UNIT_NAME=regression -JAVA_CLASSES = \ - TestMain.class \ - ../utils/AdapterBaseTestContext.class +JAVA_CLASSES+= \ + TestMain.class .PHONY: pitytest compile run test clean diff --git a/test/java/foundation/pEp/jniadapter/test/regression/TestMain.java b/test/java/foundation/pEp/jniadapter/test/regression/TestMain.java index 3b37924..d5f3bf2 100644 --- a/test/java/foundation/pEp/jniadapter/test/regression/TestMain.java +++ b/test/java/foundation/pEp/jniadapter/test/regression/TestMain.java @@ -8,7 +8,7 @@ import java.util.Vector; import static foundation.pEp.pitytest.TestLogger.log; -class CTXAlice extends AdapterBaseTestContext { +class CTXAlice extends CTXBase { @Override public CTXAlice init() throws Throwable { super.init(); @@ -28,7 +28,7 @@ class CTXAlice2 extends CTXAlice { } // Almost exact copy of JNI1118Context, we need a shared context hierarchy -class CTXReEvaluateMessageRating extends AdapterBaseTestContext { +class CTXReEvaluateMessageRating extends CTXBase { public Message msgToBobEncrypted; public Message msgToBobDecrypted; public decrypt_message_Return msgToBobDecryptResult; @@ -73,11 +73,11 @@ class TestMain { public static void main(String[] args) { TestSuite.getDefault().setVerbose(false); - new TestUnit("Engine.myself", new AdapterBaseTestContext(), ctx -> { + new TestUnit("Engine.myself", new CTXBase(), ctx -> { ctx.alice = ctx.engine.myself(ctx.alice); }); - new TestUnit("Engine.encrypt_message", new AdapterBaseTestContext(), ctx -> { + new TestUnit("Engine.encrypt_message", new CTXBase(), ctx -> { ctx.engine.encrypt_message(ctx.msgAliceToBob, null, Message.EncFormat.PEP); }); @@ -89,7 +89,7 @@ class TestMain { ctx.engine.encrypt_message_for_self(ctx.alice, ctx.msgAliceToAlice, null); }); - new TestUnit("Engine.decrypt_message", new AdapterBaseTestContext(), ctx -> { + new TestUnit("Engine.decrypt_message", new CTXBase(), ctx -> { ctx.engine.decrypt_message(ctx.msgAliceToAlice, new Vector(), 0); }); @@ -97,11 +97,11 @@ class TestMain { ctx.engine.re_evaluate_message_rating(ctx.msgToBobDecrypted); }); - new TestUnit("Engine.outgoing_message_rating", new AdapterBaseTestContext(), ctx -> { + new TestUnit("Engine.outgoing_message_rating", new CTXBase(), ctx -> { ctx.engine.outgoing_message_rating(ctx.msgAliceToBob); }); - new TestUnit("Engine.outgoing_message_rating_preview", new AdapterBaseTestContext(), ctx -> { + new TestUnit("Engine.outgoing_message_rating_preview", new CTXBase(), ctx -> { ctx.engine.outgoing_message_rating_preview(ctx.msgAliceToBob); }); @@ -113,7 +113,7 @@ class TestMain { ctx.engine.identity_rating(ctx.alice); }); - new TestUnit("Engine.blacklist_retrieve", new AdapterBaseTestContext(), ctx -> { + new TestUnit("Engine.blacklist_retrieve", new CTXBase(), ctx -> { ctx.engine.blacklist_retrieve(); }); @@ -122,19 +122,19 @@ class TestMain { // ctx.engine.own_message_private_key_details(ctx.msgToSelf); // }); - new TestUnit("Engine.OpenPGP_list_keyinfo", new AdapterBaseTestContext(), ctx -> { + new TestUnit("Engine.OpenPGP_list_keyinfo", new CTXBase(), ctx -> { ctx.engine.OpenPGP_list_keyinfo(""); }); - new TestUnit("Engine.set_identity_flags", new AdapterBaseTestContext(), ctx -> { + new TestUnit("Engine.set_identity_flags", new CTXBase(), ctx -> { ctx.engine.set_identity_flags(ctx.alice, 0); }); - new TestUnit("Engine.unset_identity_flags", new AdapterBaseTestContext(), ctx -> { + new TestUnit("Engine.unset_identity_flags", new CTXBase(), ctx -> { ctx.engine.unset_identity_flags(ctx.alice, 0); }); - new TestUnit("Engine.own_identities_retrieve", new AdapterBaseTestContext(), ctx -> { + new TestUnit("Engine.own_identities_retrieve", new CTXBase(), ctx -> { ctx.engine.own_identities_retrieve(); }); @@ -146,11 +146,11 @@ class TestMain { ctx.engine.get_trustwords_for_fprs(ctx.alice.fpr, ctx.bob.fpr, "en", false); }); - new TestUnit("Engine.get_message_trustwords", new AdapterBaseTestContext(), ctx -> { + new TestUnit("Engine.get_message_trustwords", new CTXBase(), ctx -> { ctx.engine.get_message_trustwords(ctx.msgAliceToBob, null, ctx.bob, "en", false); }); - new TestUnit("Engine.get_languagelist", new AdapterBaseTestContext(), ctx -> { + new TestUnit("Engine.get_languagelist", new CTXBase(), ctx -> { ctx.engine.get_languagelist(); }); @@ -166,12 +166,12 @@ class TestMain { ctx.engine.key_reset_user("fsdjugsh", ctx.alice.fpr); }); - new TestUnit("Engine.key_reset_all_own_keys", new AdapterBaseTestContext(), ctx -> { + new TestUnit("Engine.key_reset_all_own_keys", new CTXBase(), ctx -> { ctx.engine.key_reset_all_own_keys(); }); // TODO: FAILS -// new TestUnit("Engine.deliverHandshakeResult", new AdapterBaseTestContext(), ctx -> { +// new TestUnit("Engine.deliverHandshakeResult", new CTXBase(), ctx -> { // ctx.engine.deliverHandshakeResult(SyncHandshakeResult.SyncHandshakeCancel, ctx.vID); // }); @@ -182,7 +182,7 @@ class TestMain { // [17:52] < heck> | the error i get is: // [17:53] < heck> | *** send message KeySync Beacon service KeySync_fsm.c:234 // [17:53] < heck> | Assertion failed: (msg->from && msg->from->fpr), function attach_own_key, file message_api.c, line 1581. -// new TestUnit("Engine.leave_device_group", new AdapterBaseTestContext(), ctx -> { +// new TestUnit("Engine.leave_device_group", new CTXBase(), ctx -> { // ctx.engine.startSync(); // ctx.engine.leave_device_group(); // }); @@ -195,15 +195,15 @@ class TestMain { ctx.engine.disable_identity_for_sync(ctx.alice); }); - new TestUnit("Engine.config_cipher_suite", new AdapterBaseTestContext(), ctx -> { + new TestUnit("Engine.config_cipher_suite", new CTXBase(), ctx -> { ctx.engine.config_cipher_suite(CipherSuite.pEpCipherSuiteDefault); }); - new TestUnit("Engine.trustwords", new AdapterBaseTestContext(), ctx -> { + new TestUnit("Engine.trustwords", new CTXBase(), ctx -> { ctx.engine.trustwords(ctx.alice); }); - new TestUnit("Engine.updateIdentity", new AdapterBaseTestContext(), ctx -> { + new TestUnit("Engine.updateIdentity", new CTXBase(), ctx -> { ctx.engine.updateIdentity(ctx.alice); }); @@ -215,11 +215,11 @@ class TestMain { ctx.engine.keyMistrusted(ctx.alice); }); - new TestUnit("Engine.keyResetTrust", new AdapterBaseTestContext(), ctx -> { + new TestUnit("Engine.keyResetTrust", new CTXBase(), ctx -> { ctx.engine.keyResetTrust(ctx.alice); }); - new TestUnit("Engine.trustPersonalKey", new AdapterBaseTestContext(), ctx -> { + new TestUnit("Engine.trustPersonalKey", new CTXBase(), ctx -> { ctx.engine.trustPersonalKey(ctx.alice); }); @@ -227,84 +227,84 @@ class TestMain { ctx.engine.trustOwnKey(ctx.alice); }); - new TestUnit("Engine.importKey", new AdapterBaseTestContext(), ctx -> { + new TestUnit("Engine.importKey", new CTXBase(), ctx -> { ctx.engine.importKey(ctx.keyBobPub); }); - new TestUnit("Engine.blacklist_add", new AdapterBaseTestContext(), ctx -> { + new TestUnit("Engine.blacklist_add", new CTXBase(), ctx -> { ctx.engine.blacklist_add("43"); }); - new TestUnit("Engine.blacklist_delete", new AdapterBaseTestContext(), ctx -> { + new TestUnit("Engine.blacklist_delete", new CTXBase(), ctx -> { ctx.engine.blacklist_delete("43"); }); - new TestUnit("Engine.blacklist_is_listed", new AdapterBaseTestContext(), ctx -> { + new TestUnit("Engine.blacklist_is_listed", new CTXBase(), ctx -> { ctx.engine.blacklist_is_listed("43"); }); - new TestUnit("Engine.config_passive_mode", new AdapterBaseTestContext(), ctx -> { + new TestUnit("Engine.config_passive_mode", new CTXBase(), ctx -> { ctx.engine.config_passive_mode(false); }); - new TestUnit("Engine.config_unencrypted_subject", new AdapterBaseTestContext(), ctx -> { + new TestUnit("Engine.config_unencrypted_subject", new CTXBase(), ctx -> { ctx.engine.config_unencrypted_subject(false); }); - new TestUnit("Engine.getCrashdumpLog", new AdapterBaseTestContext(), ctx -> { + new TestUnit("Engine.getCrashdumpLog", new CTXBase(), ctx -> { ctx.engine.getCrashdumpLog(0); }); - new TestUnit("Engine.getUserDirectory", new AdapterBaseTestContext(), ctx -> { + new TestUnit("Engine.getUserDirectory", new CTXBase(), ctx -> { ctx.engine.getUserDirectory(); }); - new TestUnit("Engine.getMachineDirectory", new AdapterBaseTestContext(), ctx -> { + new TestUnit("Engine.getMachineDirectory", new CTXBase(), ctx -> { ctx.engine.getMachineDirectory(); }); // AbstractEngine.java - new TestUnit("Engine.close", new AdapterBaseTestContext(), ctx -> { + new TestUnit("Engine.close", new CTXBase(), ctx -> { ctx.engine.close(); }); - new TestUnit("Engine.getVersion", new AdapterBaseTestContext(), ctx -> { + new TestUnit("Engine.getVersion", new CTXBase(), ctx -> { ctx.engine.getVersion(); }); - new TestUnit("Engine.getProtocolVersion", new AdapterBaseTestContext(), ctx -> { + new TestUnit("Engine.getProtocolVersion", new CTXBase(), ctx -> { ctx.engine.getProtocolVersion(); }); - new TestUnit("Engine.startKeyserverLookup", new AdapterBaseTestContext(), ctx -> { + new TestUnit("Engine.startKeyserverLookup", new CTXBase(), ctx -> { ctx.engine.startKeyserverLookup(); }); - new TestUnit("Engine.startSync", new AdapterBaseTestContext(), ctx -> { + new TestUnit("Engine.startSync", new CTXBase(), ctx -> { ctx.engine.startSync(); }); - new TestUnit("Engine.stopSync", new AdapterBaseTestContext(), ctx -> { + new TestUnit("Engine.stopSync", new CTXBase(), ctx -> { ctx.engine.stopSync(); }); - new TestUnit("Engine.isSyncRunning", new AdapterBaseTestContext(), ctx -> { + new TestUnit("Engine.isSyncRunning", new CTXBase(), ctx -> { ctx.engine.isSyncRunning(); }); - new TestUnit("Engine.config_passphrase",new AdapterBaseTestContext() , ctx -> { + new TestUnit("Engine.config_passphrase",new CTXBase() , ctx -> { ctx.engine.config_passphrase("SUPERCOMPLICATEDPASSPHRASE"); }); - new TestUnit("Engine.config_passphrase_for_new_keys",new AdapterBaseTestContext() , ctx -> { + new TestUnit("Engine.config_passphrase_for_new_keys",new CTXBase() , ctx -> { ctx.engine.config_passphrase_for_new_keys(true, "SUPERCOMPLICATEDPASSPHRASE"); }); - new TestUnit("Engine.setDebugLogEnabled", new AdapterBaseTestContext(), ctx -> { + new TestUnit("Engine.setDebugLogEnabled", new CTXBase(), ctx -> { Engine.setDebugLogEnabled(true); }); - new TestUnit("Engine.setDebugLogEnabled", new AdapterBaseTestContext(), ctx -> { + new TestUnit("Engine.setDebugLogEnabled", new CTXBase(), ctx -> { Engine.getDebugLogEnabled(); }); diff --git a/test/java/foundation/pEp/jniadapter/test/speedtest/Makefile b/test/java/foundation/pEp/jniadapter/test/speedtest/Makefile index 8506bd1..26ddb95 100644 --- a/test/java/foundation/pEp/jniadapter/test/speedtest/Makefile +++ b/test/java/foundation/pEp/jniadapter/test/speedtest/Makefile @@ -3,7 +3,7 @@ include ../Makefile.conf TEST_UNIT_NAME=speedtest -JAVA_CLASSES = \ +JAVA_CLASSES+= \ MT999.class \ MTConstants.class \ MTMsgCodec.class \ diff --git a/test/java/foundation/pEp/jniadapter/test/templateAlice/Makefile b/test/java/foundation/pEp/jniadapter/test/templateAlice/Makefile index e0799fa..594499b 100644 --- a/test/java/foundation/pEp/jniadapter/test/templateAlice/Makefile +++ b/test/java/foundation/pEp/jniadapter/test/templateAlice/Makefile @@ -3,11 +3,8 @@ include ../Makefile.conf TEST_UNIT_NAME=templateAlice -JAVA_CLASSES = \ - TestAlice.class \ - ../utils/AdapterBaseTestContext.class \ - ../utils/AdapterTestUtils.class \ - ../utils/TestCallbacks.class +JAVA_CLASSES+= \ + TestAlice.class .PHONY: pitytest compile alice test clean diff --git a/test/java/foundation/pEp/jniadapter/test/templateAlice/TestAlice.java b/test/java/foundation/pEp/jniadapter/test/templateAlice/TestAlice.java index 9904bf2..8f5037c 100644 --- a/test/java/foundation/pEp/jniadapter/test/templateAlice/TestAlice.java +++ b/test/java/foundation/pEp/jniadapter/test/templateAlice/TestAlice.java @@ -9,7 +9,7 @@ class TestAlice { TestSuite.getDefault().setVerbose(true); TestSuite.getDefault().setTestColor(TestUtils.TermColor.GREEN); - new TestUnit("Test Alice",new AdapterBaseTestContext() , ctx -> { + new TestUnit("Test Alice",new CTXBase() , ctx -> { // do stuff using the context // throw or assert, to let a testunit fail diff --git a/test/java/foundation/pEp/jniadapter/test/templateAliceBob/Makefile b/test/java/foundation/pEp/jniadapter/test/templateAliceBob/Makefile index 7cb17b3..df8aeb6 100644 --- a/test/java/foundation/pEp/jniadapter/test/templateAliceBob/Makefile +++ b/test/java/foundation/pEp/jniadapter/test/templateAliceBob/Makefile @@ -3,15 +3,12 @@ include ../Makefile.conf TEST_UNIT_NAME=templateAliceBob -JAVA_CLASSES = \ +JAVA_CLASSES+= \ TestAlice.class \ TestBob.class \ MultiPeerCTX.class \ Utils.class \ - TransportMessage.class \ - ../utils/AdapterBaseTestContext.class \ - ../utils/AdapterTestUtils.class \ - ../utils/TestCallbacks.class + TransportMessage.class .PHONY: pitytest compile alice bob test clean diff --git a/test/java/foundation/pEp/jniadapter/test/templateAliceBobCarol/Makefile b/test/java/foundation/pEp/jniadapter/test/templateAliceBobCarol/Makefile index 63cc519..ab91504 100644 --- a/test/java/foundation/pEp/jniadapter/test/templateAliceBobCarol/Makefile +++ b/test/java/foundation/pEp/jniadapter/test/templateAliceBobCarol/Makefile @@ -3,13 +3,10 @@ include ../Makefile.conf TEST_UNIT_NAME=templateAliceBobCarol -JAVA_CLASSES = \ +JAVA_CLASSES+= \ TestAlice.class \ TestBob.class \ - TestCarol.class \ - ../utils/AdapterBaseTestContext.class \ - ../utils/AdapterTestUtils.class \ - ../utils/TestCallbacks.class + TestCarol.class .PHONY: pitytest compile alice bob carol test clean diff --git a/test/java/foundation/pEp/jniadapter/test/templateAliceBobCarol/TestAlice.java b/test/java/foundation/pEp/jniadapter/test/templateAliceBobCarol/TestAlice.java index adc0d98..b99a792 100644 --- a/test/java/foundation/pEp/jniadapter/test/templateAliceBobCarol/TestAlice.java +++ b/test/java/foundation/pEp/jniadapter/test/templateAliceBobCarol/TestAlice.java @@ -9,7 +9,7 @@ class TestAlice { TestSuite.getDefault().setVerbose(true); TestSuite.getDefault().setTestColor(TestUtils.TermColor.GREEN); - new TestUnit("Test Alice",new AdapterBaseTestContext() , ctx -> { + new TestUnit("Test Alice",new CTXBase() , ctx -> { // do stuff using the context // throw or assert, to let a testunit fail diff --git a/test/java/foundation/pEp/jniadapter/test/templateAliceBobCarol/TestBob.java b/test/java/foundation/pEp/jniadapter/test/templateAliceBobCarol/TestBob.java index 67410c6..f961b9d 100644 --- a/test/java/foundation/pEp/jniadapter/test/templateAliceBobCarol/TestBob.java +++ b/test/java/foundation/pEp/jniadapter/test/templateAliceBobCarol/TestBob.java @@ -9,7 +9,7 @@ class TestBob { TestSuite.getDefault().setVerbose(true); TestSuite.getDefault().setTestColor(TestUtils.TermColor.YELLOW); - new TestUnit("Test Bob",new AdapterBaseTestContext() , ctx -> { + new TestUnit("Test Bob",new CTXBase() , ctx -> { // do stuff using the context // throw or assert, to let a testunit fail diff --git a/test/java/foundation/pEp/jniadapter/test/templateAliceBobCarol/TestCarol.java b/test/java/foundation/pEp/jniadapter/test/templateAliceBobCarol/TestCarol.java index 3f90625..adcda4f 100644 --- a/test/java/foundation/pEp/jniadapter/test/templateAliceBobCarol/TestCarol.java +++ b/test/java/foundation/pEp/jniadapter/test/templateAliceBobCarol/TestCarol.java @@ -9,7 +9,7 @@ class TestCarol { TestSuite.getDefault().setVerbose(true); TestSuite.getDefault().setTestColor(TestUtils.TermColor.RED); - new TestUnit("Test Carol",new AdapterBaseTestContext() , ctx -> { + new TestUnit("Test Carol",new CTXBase() , ctx -> { // do stuff using the context // throw or assert, to let a testunit fail diff --git a/test/java/foundation/pEp/jniadapter/test/utils/AdapterBaseTestContext.java b/test/java/foundation/pEp/jniadapter/test/utils/CTXBase.java similarity index 95% rename from test/java/foundation/pEp/jniadapter/test/utils/AdapterBaseTestContext.java rename to test/java/foundation/pEp/jniadapter/test/utils/CTXBase.java index 1a39e73..25d18cb 100644 --- a/test/java/foundation/pEp/jniadapter/test/utils/AdapterBaseTestContext.java +++ b/test/java/foundation/pEp/jniadapter/test/utils/CTXBase.java @@ -12,7 +12,7 @@ import java.nio.file.Path; import java.nio.file.Paths; -//public class ABAliceTestContext extends AdapterBaseTestContext { +//public class ABAliceTestContext extends CTXBase { // FsMQManager transport; // // @Override @@ -30,7 +30,7 @@ import java.nio.file.Paths; -public class AdapterBaseTestContext extends AbstractTestContext { +public class CTXBase extends AbstractTestContext { // Basic public Engine engine; public TestCallbacks callbacks; @@ -72,7 +72,7 @@ public class AdapterBaseTestContext extends AbstractTestContext { public AttachmentList attachmentList = new AttachmentList(3,10000); - public AdapterBaseTestContext init() throws Throwable { + public CTXBase init() throws Throwable { callbacks = new TestCallbacks(); engine = new Engine(); engine.setMessageToSendCallback(callbacks); diff --git a/test/java/foundation/pEp/jniadapter/test/utils/transport/fsmqmanager/test/identities/Makefile b/test/java/foundation/pEp/jniadapter/test/utils/transport/fsmqmanager/test/identities/Makefile index 408c8b9..1521d24 100644 --- a/test/java/foundation/pEp/jniadapter/test/utils/transport/fsmqmanager/test/identities/Makefile +++ b/test/java/foundation/pEp/jniadapter/test/utils/transport/fsmqmanager/test/identities/Makefile @@ -2,8 +2,8 @@ include ../Makefile.conf TEST_UNIT_NAME=identities -JAVA_CLASSES = \ - TestMain.class \ +JAVA_CLASSES+= \ + TestMain.class JAVA_CLASSES += $(JAVA_CLASSES_FSMSGQUEUE) JAVA_CLASSES += $(JAVA_CLASSES_TESTSCOMMON) diff --git a/test/java/foundation/pEp/jniadapter/test/utils/transport/fsmqmanager/test/stateless_ping/Makefile b/test/java/foundation/pEp/jniadapter/test/utils/transport/fsmqmanager/test/stateless_ping/Makefile index 5702d25..d790c29 100644 --- a/test/java/foundation/pEp/jniadapter/test/utils/transport/fsmqmanager/test/stateless_ping/Makefile +++ b/test/java/foundation/pEp/jniadapter/test/utils/transport/fsmqmanager/test/stateless_ping/Makefile @@ -2,7 +2,7 @@ include ../Makefile.conf TEST_UNIT_NAME=stateless_ping -JAVA_CLASSES = \ +JAVA_CLASSES+= \ TestAlice.class \ TestBob.class diff --git a/test/java/foundation/pEp/jniadapter/test/utils/transport/fsmqmanager/test/stateless_rxtx/Makefile b/test/java/foundation/pEp/jniadapter/test/utils/transport/fsmqmanager/test/stateless_rxtx/Makefile index cfa1548..87337ec 100644 --- a/test/java/foundation/pEp/jniadapter/test/utils/transport/fsmqmanager/test/stateless_rxtx/Makefile +++ b/test/java/foundation/pEp/jniadapter/test/utils/transport/fsmqmanager/test/stateless_rxtx/Makefile @@ -2,8 +2,8 @@ include ../Makefile.conf TEST_UNIT_NAME=stateless_rxtx -JAVA_CLASSES = \ - TestMain.class \ +JAVA_CLASSES+= \ + TestMain.class JAVA_CLASSES += $(JAVA_CLASSES_FSMSGQUEUE) JAVA_CLASSES += $(JAVA_CLASSES_TESTSCOMMON) diff --git a/test/java/foundation/pEp/jniadapter/test/utils/transport/fsmsgqueue/test/regression/Makefile b/test/java/foundation/pEp/jniadapter/test/utils/transport/fsmsgqueue/test/regression/Makefile index e02b539..b243826 100644 --- a/test/java/foundation/pEp/jniadapter/test/utils/transport/fsmsgqueue/test/regression/Makefile +++ b/test/java/foundation/pEp/jniadapter/test/utils/transport/fsmsgqueue/test/regression/Makefile @@ -2,8 +2,8 @@ include ../Makefile.conf TEST_UNIT_NAME=regression -JAVA_CLASSES = \ - TestMain.class \ +JAVA_CLASSES+= \ + TestMain.class JAVA_CLASSES += $(JAVA_CLASSES_FSMSGQUEUE) JAVA_CLASSES += $(JAVA_CLASSES_TESTSCOMMON) diff --git a/test/java/foundation/pEp/pitytest/Makefile b/test/java/foundation/pEp/pitytest/Makefile index 203bfab..df30d36 100644 --- a/test/java/foundation/pEp/pitytest/Makefile +++ b/test/java/foundation/pEp/pitytest/Makefile @@ -2,7 +2,7 @@ include Makefile.conf PKGNAME=pitytest -JAVA_CLASSES = $(JAVA_CLASSES_PITYTEST) +JAVA_CLASSES+= $(JAVA_CLASSES_PITYTEST) .PHONY: all compile clean diff --git a/test/java/foundation/pEp/pitytest/examples/ctxinitfail/Makefile b/test/java/foundation/pEp/pitytest/examples/ctxinitfail/Makefile index d36de9d..46a60ad 100644 --- a/test/java/foundation/pEp/pitytest/examples/ctxinitfail/Makefile +++ b/test/java/foundation/pEp/pitytest/examples/ctxinitfail/Makefile @@ -3,8 +3,8 @@ include ../Makefile.conf TEST_UNIT_NAME=ctxinitfail -JAVA_CLASSES = \ - TestMain.class \ +JAVA_CLASSES+= \ + TestMain.class # Use PityTest JAVA_CLASSES += $(JAVA_CLASSES_PITYTEST) diff --git a/test/java/foundation/pEp/pitytest/examples/ctxmembers/Makefile b/test/java/foundation/pEp/pitytest/examples/ctxmembers/Makefile index 035fab6..e5ee1ff 100644 --- a/test/java/foundation/pEp/pitytest/examples/ctxmembers/Makefile +++ b/test/java/foundation/pEp/pitytest/examples/ctxmembers/Makefile @@ -3,8 +3,8 @@ include ../Makefile.conf TEST_UNIT_NAME=ctxmembers -JAVA_CLASSES = \ - TestMain.class \ +JAVA_CLASSES+= \ + TestMain.class # Use PityTest JAVA_CLASSES += $(JAVA_CLASSES_PITYTEST) diff --git a/test/java/foundation/pEp/pitytest/examples/helloworld/Makefile b/test/java/foundation/pEp/pitytest/examples/helloworld/Makefile index 2431ab4..c0532ad 100644 --- a/test/java/foundation/pEp/pitytest/examples/helloworld/Makefile +++ b/test/java/foundation/pEp/pitytest/examples/helloworld/Makefile @@ -3,8 +3,8 @@ include ../Makefile.conf TEST_UNIT_NAME=helloworld -JAVA_CLASSES = \ - TestMain.class \ +JAVA_CLASSES+= \ + TestMain.class # Use PityTest JAVA_CLASSES += $(JAVA_CLASSES_PITYTEST) diff --git a/test/java/foundation/pEp/pitytest/examples/testsuite/Makefile b/test/java/foundation/pEp/pitytest/examples/testsuite/Makefile index 66009d0..e34a8bf 100644 --- a/test/java/foundation/pEp/pitytest/examples/testsuite/Makefile +++ b/test/java/foundation/pEp/pitytest/examples/testsuite/Makefile @@ -3,8 +3,8 @@ include ../Makefile.conf TEST_UNIT_NAME=testsuite -JAVA_CLASSES = \ - TestMain.class \ +JAVA_CLASSES+= \ + TestMain.class # Use PityTest JAVA_CLASSES += $(JAVA_CLASSES_PITYTEST)