*
Warning This class is probably incomplete. If your testing requirements
@@ -132,7 +128,6 @@
public class Scenario {
private static final Logger log = LoggerFactory.getLogger(Scenario.class);
public static final FormIndex BEGINNING_OF_FORM = FormIndex.createBeginningOfFormIndex();
- private Path formFile;
private final FormDef formDef;
private FormEntryController controller;
private EvaluationContext evaluationContext;
@@ -268,17 +263,17 @@ public Scenario serializeAndDeserializeForm() throws IOException, Deserializatio
new XFormsModule().registerModule();
// Serialize form in a temp file
- Path tempFile = createTempFile("javarosa", "test");
- formDef.writeExternal(new DataOutputStream(newOutputStream(tempFile)));
+ File tempFile = TempFileUtils.createTempFile("javarosa", "test");
+ formDef.writeExternal(new DataOutputStream(new FileOutputStream(tempFile)));
// Create an empty FormDef and deserialize the form into it
FormDef deserializedFormDef = new FormDef();
deserializedFormDef.readExternal(
- new DataInputStream(newInputStream(tempFile)),
+ new DataInputStream(new FileInputStream(tempFile)),
PrototypeManager.getDefault()
);
- delete(tempFile);
+ tempFile.delete();
deserializedFormDef.initialize(false, new InstanceInitializationFactory());
return Scenario.from(deserializedFormDef);
}
@@ -434,18 +429,20 @@ private FormIndex getIndexOf(TreeReference ref) {
*/
// TODO Extract the form's name from the provided XFormsElement object to simplify args
public static Scenario init(String formName, XFormsElement form) throws IOException, XFormParser.ParseException {
- Path formFile = createTempDirectory("javarosa").resolve(formName + ".xml");
+ File tempDir = TempFileUtils.createTempDir("javarosa");
+ File formFile = TempFileUtils.createTempFile(tempDir, formName, "xml");
String xml = form.asXml();
System.out.println(xml);
- write(formFile, xml.getBytes(UTF_8), CREATE);
+ FileUtils.write(formFile, xml, UTF_8);
return Scenario.init(formFile);
}
public static FormDef createFormDef(String formName, XFormsElement form) throws IOException, XFormParser.ParseException {
- Path formFile = createTempDirectory("javarosa").resolve(formName + ".xml");
+ File tempDir = TempFileUtils.createTempDir("javarosa");
+ File formFile = TempFileUtils.createTempFile(tempDir, formName, "xml");
String xml = form.asXml();
System.out.println(xml);
- write(formFile, xml.getBytes(UTF_8), CREATE);
+ FileUtils.write(formFile, xml, UTF_8);
return Scenario.createFormDef(formFile);
}
@@ -455,13 +452,13 @@ public static FormDef createFormDef(String formName, XFormsElement form) throws
* A form with the provided filename must exist in the classpath
*/
public static Scenario init(String formFileName) throws XFormParser.ParseException {
- return init(r(formFileName));
+ return init(ResourcePathHelper.r(formFileName));
}
/**
* Initializes the Scenario with the form at the provided path
*/
- public static Scenario init(Path formFile) throws XFormParser.ParseException {
+ public static Scenario init(File formFile) throws XFormParser.ParseException {
FormDef formDef = createFormDef(formFile);
formDef.initialize(true, new InstanceInitializationFactory());
return Scenario.from(formDef);
@@ -473,7 +470,7 @@ public static Scenario init(FormDef formDef) throws XFormParser.ParseException {
}
@NotNull
- public static FormDef createFormDef(Path formFile) throws XFormParser.ParseException {
+ public static FormDef createFormDef(File formFile) throws XFormParser.ParseException {
// TODO explain why this sequence of calls
StorageManager.setStorageFactory((name, type) -> new DummyIndexedStorageUtility<>());
new XFormsModule().registerModule();
@@ -610,7 +607,7 @@ public AnswerResult answer(char value) {
* Answers the question at the form index
*/
public AnswerResult answer(LocalDate value) {
- return answer(new DateData(Date.valueOf(value)));
+ return answer(new DateData(Date.from(value.atStartOfDay(ZoneId.of("UTC")).toInstant())));
}
/**
diff --git a/src/test/java/org/javarosa/core/util/StringLiteralXFormsElement.java b/src/main/java/org/javarosa/test/StringLiteralXFormsElement.java
similarity index 88%
rename from src/test/java/org/javarosa/core/util/StringLiteralXFormsElement.java
rename to src/main/java/org/javarosa/test/StringLiteralXFormsElement.java
index b8acc0ef1..d05967fc1 100644
--- a/src/test/java/org/javarosa/core/util/StringLiteralXFormsElement.java
+++ b/src/main/java/org/javarosa/test/StringLiteralXFormsElement.java
@@ -14,13 +14,13 @@
* limitations under the License.
*/
-package org.javarosa.core.util;
+package org.javarosa.test;
-import static org.javarosa.core.util.XFormsElement.buildAttributesString;
+import static org.javarosa.test.XFormsElement.buildAttributesString;
import java.util.Map;
-public class StringLiteralXFormsElement implements XFormsElement {
+class StringLiteralXFormsElement implements XFormsElement {
private final String name;
private final Map
attributes;
private final String innerHtml;
diff --git a/src/test/java/org/javarosa/core/util/TagXFormsElement.java b/src/main/java/org/javarosa/test/TagXFormsElement.java
similarity index 90%
rename from src/test/java/org/javarosa/core/util/TagXFormsElement.java
rename to src/main/java/org/javarosa/test/TagXFormsElement.java
index 621380744..4d0cb754f 100644
--- a/src/test/java/org/javarosa/core/util/TagXFormsElement.java
+++ b/src/main/java/org/javarosa/test/TagXFormsElement.java
@@ -14,14 +14,14 @@
* limitations under the License.
*/
-package org.javarosa.core.util;
+package org.javarosa.test;
-import static org.javarosa.core.util.XFormsElement.buildAttributesString;
+import static org.javarosa.test.XFormsElement.buildAttributesString;
import java.util.List;
import java.util.Map;
-public class TagXFormsElement implements XFormsElement {
+class TagXFormsElement implements XFormsElement {
private final String name;
private final Map attributes;
private final List children;
diff --git a/src/main/java/org/javarosa/test/TempFileUtils.java b/src/main/java/org/javarosa/test/TempFileUtils.java
new file mode 100644
index 000000000..a1f52f791
--- /dev/null
+++ b/src/main/java/org/javarosa/test/TempFileUtils.java
@@ -0,0 +1,29 @@
+package org.javarosa.test;
+
+import java.io.File;
+import java.io.IOException;
+import java.util.UUID;
+
+public class TempFileUtils {
+
+ static File createTempDir(String name) {
+ File tempDir = new File(System.getProperty("java.io.tmpdir"));
+ File subDir = new File(tempDir, name + UUID.randomUUID().toString());
+ subDir.mkdir();
+ return subDir;
+ }
+
+ static File createTempFile(String prefix, String suffix) {
+ return createTempFile(null, prefix, suffix);
+ }
+
+ public static File createTempFile(File parent, String prefix, String suffix) {
+ try {
+ File tempFile = File.createTempFile(prefix, suffix, parent);
+ tempFile.deleteOnExit();
+ return tempFile;
+ } catch (IOException e) {
+ throw new RuntimeException(e);
+ }
+ }
+}
diff --git a/src/test/java/org/javarosa/core/util/XFormsElement.java b/src/main/java/org/javarosa/test/XFormsElement.java
similarity index 99%
rename from src/test/java/org/javarosa/core/util/XFormsElement.java
rename to src/main/java/org/javarosa/test/XFormsElement.java
index 022d0f981..7047c7731 100644
--- a/src/test/java/org/javarosa/core/util/XFormsElement.java
+++ b/src/main/java/org/javarosa/test/XFormsElement.java
@@ -14,7 +14,7 @@
* limitations under the License.
*/
-package org.javarosa.core.util;
+package org.javarosa.test;
import kotlin.Pair;
diff --git a/src/test/java/org/javarosa/core/form/api/test/TextFormTests.java b/src/test/java/org/javarosa/core/form/api/test/TextFormTests.java
index 8a75dd15b..7bc396e77 100644
--- a/src/test/java/org/javarosa/core/form/api/test/TextFormTests.java
+++ b/src/test/java/org/javarosa/core/form/api/test/TextFormTests.java
@@ -13,7 +13,7 @@
import org.javarosa.core.services.PrototypeManager;
import org.javarosa.core.services.locale.Localizer;
import org.javarosa.core.services.locale.TableLocaleSource;
-import org.javarosa.core.test.FormParseInit;
+import org.javarosa.test.FormParseInit;
import org.javarosa.core.util.externalizable.ExtUtil;
import org.javarosa.core.util.externalizable.PrototypeFactory;
import org.javarosa.form.api.FormEntryCaption;
diff --git a/src/test/java/org/javarosa/core/model/ChoiceNameTest.java b/src/test/java/org/javarosa/core/model/ChoiceNameTest.java
index 71219841f..1c4d26586 100644
--- a/src/test/java/org/javarosa/core/model/ChoiceNameTest.java
+++ b/src/test/java/org/javarosa/core/model/ChoiceNameTest.java
@@ -3,22 +3,22 @@
import static org.hamcrest.MatcherAssert.assertThat;
import static org.hamcrest.core.Is.is;
import static org.javarosa.core.test.AnswerDataMatchers.stringAnswer;
-import static org.javarosa.core.util.BindBuilderXFormsElement.bind;
-import static org.javarosa.core.util.XFormsElement.body;
-import static org.javarosa.core.util.XFormsElement.head;
-import static org.javarosa.core.util.XFormsElement.html;
-import static org.javarosa.core.util.XFormsElement.item;
-import static org.javarosa.core.util.XFormsElement.mainInstance;
-import static org.javarosa.core.util.XFormsElement.model;
-import static org.javarosa.core.util.XFormsElement.repeat;
-import static org.javarosa.core.util.XFormsElement.select1;
-import static org.javarosa.core.util.XFormsElement.select1Dynamic;
-import static org.javarosa.core.util.XFormsElement.t;
-import static org.javarosa.core.util.XFormsElement.title;
-import static org.javarosa.test.utils.ResourcePathHelper.r;
+import static org.javarosa.test.BindBuilderXFormsElement.bind;
+import static org.javarosa.test.XFormsElement.body;
+import static org.javarosa.test.XFormsElement.head;
+import static org.javarosa.test.XFormsElement.html;
+import static org.javarosa.test.XFormsElement.item;
+import static org.javarosa.test.XFormsElement.mainInstance;
+import static org.javarosa.test.XFormsElement.model;
+import static org.javarosa.test.XFormsElement.repeat;
+import static org.javarosa.test.XFormsElement.select1;
+import static org.javarosa.test.XFormsElement.select1Dynamic;
+import static org.javarosa.test.XFormsElement.t;
+import static org.javarosa.test.XFormsElement.title;
+import static org.javarosa.test.ResourcePathHelper.r;
import java.io.IOException;
-import org.javarosa.core.test.Scenario;
+import org.javarosa.test.Scenario;
import org.javarosa.xform.parse.XFormParser;
import org.junit.Test;
diff --git a/src/test/java/org/javarosa/core/model/DynamicSelectUpdateTest.java b/src/test/java/org/javarosa/core/model/DynamicSelectUpdateTest.java
index 50d90050d..5d49711cb 100644
--- a/src/test/java/org/javarosa/core/model/DynamicSelectUpdateTest.java
+++ b/src/test/java/org/javarosa/core/model/DynamicSelectUpdateTest.java
@@ -23,22 +23,22 @@
import static org.hamcrest.Matchers.not;
import static org.hamcrest.Matchers.sameInstance;
import static org.javarosa.core.test.SelectChoiceMatchers.choice;
-import static org.javarosa.core.util.XFormsElement.body;
-import static org.javarosa.core.util.XFormsElement.head;
-import static org.javarosa.core.util.XFormsElement.html;
-import static org.javarosa.core.util.XFormsElement.input;
-import static org.javarosa.core.util.XFormsElement.instance;
-import static org.javarosa.core.util.XFormsElement.item;
-import static org.javarosa.core.util.XFormsElement.mainInstance;
-import static org.javarosa.core.util.XFormsElement.model;
-import static org.javarosa.core.util.XFormsElement.repeat;
-import static org.javarosa.core.util.XFormsElement.select1Dynamic;
-import static org.javarosa.core.util.XFormsElement.t;
-import static org.javarosa.core.util.XFormsElement.title;
+import static org.javarosa.test.XFormsElement.body;
+import static org.javarosa.test.XFormsElement.head;
+import static org.javarosa.test.XFormsElement.html;
+import static org.javarosa.test.XFormsElement.input;
+import static org.javarosa.test.XFormsElement.instance;
+import static org.javarosa.test.XFormsElement.item;
+import static org.javarosa.test.XFormsElement.mainInstance;
+import static org.javarosa.test.XFormsElement.model;
+import static org.javarosa.test.XFormsElement.repeat;
+import static org.javarosa.test.XFormsElement.select1Dynamic;
+import static org.javarosa.test.XFormsElement.t;
+import static org.javarosa.test.XFormsElement.title;
import java.util.List;
-import org.javarosa.core.test.Scenario;
-import org.javarosa.core.util.XFormsElement;
+import org.javarosa.test.Scenario;
+import org.javarosa.test.XFormsElement;
import org.junit.Test;
/**
diff --git a/src/test/java/org/javarosa/core/model/FormDefSerializationTest.java b/src/test/java/org/javarosa/core/model/FormDefSerializationTest.java
index ace7832ff..35dd079b6 100644
--- a/src/test/java/org/javarosa/core/model/FormDefSerializationTest.java
+++ b/src/test/java/org/javarosa/core/model/FormDefSerializationTest.java
@@ -19,18 +19,18 @@
import static org.hamcrest.CoreMatchers.is;
import static org.hamcrest.MatcherAssert.assertThat;
import static org.hamcrest.core.IsNull.nullValue;
-import static org.javarosa.core.util.BindBuilderXFormsElement.bind;
-import static org.javarosa.core.util.XFormsElement.body;
-import static org.javarosa.core.util.XFormsElement.head;
-import static org.javarosa.core.util.XFormsElement.html;
-import static org.javarosa.core.util.XFormsElement.input;
-import static org.javarosa.core.util.XFormsElement.mainInstance;
-import static org.javarosa.core.util.XFormsElement.model;
-import static org.javarosa.core.util.XFormsElement.t;
-import static org.javarosa.core.util.XFormsElement.title;
+import static org.javarosa.test.BindBuilderXFormsElement.bind;
+import static org.javarosa.test.XFormsElement.body;
+import static org.javarosa.test.XFormsElement.head;
+import static org.javarosa.test.XFormsElement.html;
+import static org.javarosa.test.XFormsElement.input;
+import static org.javarosa.test.XFormsElement.mainInstance;
+import static org.javarosa.test.XFormsElement.model;
+import static org.javarosa.test.XFormsElement.t;
+import static org.javarosa.test.XFormsElement.title;
import java.io.IOException;
-import org.javarosa.core.test.Scenario;
+import org.javarosa.test.Scenario;
import org.javarosa.core.util.externalizable.DeserializationException;
import org.javarosa.xform.parse.XFormParser;
import org.junit.Test;
diff --git a/src/test/java/org/javarosa/core/model/FormIndexTest.java b/src/test/java/org/javarosa/core/model/FormIndexTest.java
index ee57ee342..4486bcb65 100644
--- a/src/test/java/org/javarosa/core/model/FormIndexTest.java
+++ b/src/test/java/org/javarosa/core/model/FormIndexTest.java
@@ -6,7 +6,7 @@
import static org.hamcrest.Matchers.is;
import static org.hamcrest.Matchers.nullValue;
import static org.javarosa.core.model.FormIndex.createBeginningOfFormIndex;
-import static org.javarosa.core.test.Scenario.getRef;
+import static org.javarosa.test.Scenario.getRef;
public class FormIndexTest {
diff --git a/src/test/java/org/javarosa/core/model/PredicateCachingTest.java b/src/test/java/org/javarosa/core/model/PredicateCachingTest.java
index f0c12b047..5bbf79969 100644
--- a/src/test/java/org/javarosa/core/model/PredicateCachingTest.java
+++ b/src/test/java/org/javarosa/core/model/PredicateCachingTest.java
@@ -6,21 +6,21 @@
import static org.hamcrest.Matchers.greaterThan;
import static org.hamcrest.Matchers.lessThan;
import static org.hamcrest.Matchers.not;
-import static org.javarosa.core.util.BindBuilderXFormsElement.bind;
-import static org.javarosa.core.util.XFormsElement.body;
-import static org.javarosa.core.util.XFormsElement.group;
-import static org.javarosa.core.util.XFormsElement.head;
-import static org.javarosa.core.util.XFormsElement.html;
-import static org.javarosa.core.util.XFormsElement.input;
-import static org.javarosa.core.util.XFormsElement.instance;
-import static org.javarosa.core.util.XFormsElement.item;
-import static org.javarosa.core.util.XFormsElement.mainInstance;
-import static org.javarosa.core.util.XFormsElement.model;
-import static org.javarosa.core.util.XFormsElement.repeat;
-import static org.javarosa.core.util.XFormsElement.t;
-import static org.javarosa.core.util.XFormsElement.title;
-
-import org.javarosa.core.test.Scenario;
+import static org.javarosa.test.BindBuilderXFormsElement.bind;
+import static org.javarosa.test.XFormsElement.body;
+import static org.javarosa.test.XFormsElement.group;
+import static org.javarosa.test.XFormsElement.head;
+import static org.javarosa.test.XFormsElement.html;
+import static org.javarosa.test.XFormsElement.input;
+import static org.javarosa.test.XFormsElement.instance;
+import static org.javarosa.test.XFormsElement.item;
+import static org.javarosa.test.XFormsElement.mainInstance;
+import static org.javarosa.test.XFormsElement.model;
+import static org.javarosa.test.XFormsElement.repeat;
+import static org.javarosa.test.XFormsElement.t;
+import static org.javarosa.test.XFormsElement.title;
+
+import org.javarosa.test.Scenario;
import org.javarosa.measure.Measure;
import org.junit.Test;
diff --git a/src/test/java/org/javarosa/core/model/RepeatTest.java b/src/test/java/org/javarosa/core/model/RepeatTest.java
index 8a9643201..d121a1b50 100644
--- a/src/test/java/org/javarosa/core/model/RepeatTest.java
+++ b/src/test/java/org/javarosa/core/model/RepeatTest.java
@@ -2,22 +2,22 @@
import static org.hamcrest.MatcherAssert.assertThat;
import static org.hamcrest.Matchers.is;
-import static org.javarosa.core.util.BindBuilderXFormsElement.bind;
-import static org.javarosa.core.util.XFormsElement.body;
-import static org.javarosa.core.util.XFormsElement.head;
-import static org.javarosa.core.util.XFormsElement.html;
-import static org.javarosa.core.util.XFormsElement.input;
-import static org.javarosa.core.util.XFormsElement.item;
-import static org.javarosa.core.util.XFormsElement.mainInstance;
-import static org.javarosa.core.util.XFormsElement.model;
-import static org.javarosa.core.util.XFormsElement.repeat;
-import static org.javarosa.core.util.XFormsElement.select1;
-import static org.javarosa.core.util.XFormsElement.t;
-import static org.javarosa.core.util.XFormsElement.title;
+import static org.javarosa.test.BindBuilderXFormsElement.bind;
+import static org.javarosa.test.XFormsElement.body;
+import static org.javarosa.test.XFormsElement.head;
+import static org.javarosa.test.XFormsElement.html;
+import static org.javarosa.test.XFormsElement.input;
+import static org.javarosa.test.XFormsElement.item;
+import static org.javarosa.test.XFormsElement.mainInstance;
+import static org.javarosa.test.XFormsElement.model;
+import static org.javarosa.test.XFormsElement.repeat;
+import static org.javarosa.test.XFormsElement.select1;
+import static org.javarosa.test.XFormsElement.t;
+import static org.javarosa.test.XFormsElement.title;
import java.io.IOException;
import org.javarosa.core.model.data.IntegerData;
-import org.javarosa.core.test.Scenario;
+import org.javarosa.test.Scenario;
import org.javarosa.form.api.FormEntryController;
import org.javarosa.xform.parse.XFormParser;
import org.junit.Test;
diff --git a/src/test/java/org/javarosa/core/model/SelectCachingTest.java b/src/test/java/org/javarosa/core/model/SelectCachingTest.java
index f5f78c365..711fa2d09 100644
--- a/src/test/java/org/javarosa/core/model/SelectCachingTest.java
+++ b/src/test/java/org/javarosa/core/model/SelectCachingTest.java
@@ -4,21 +4,21 @@
import static org.hamcrest.MatcherAssert.assertThat;
import static org.hamcrest.Matchers.equalTo;
import static org.hamcrest.Matchers.lessThan;
-import static org.javarosa.core.util.BindBuilderXFormsElement.bind;
-import static org.javarosa.core.util.XFormsElement.body;
-import static org.javarosa.core.util.XFormsElement.head;
-import static org.javarosa.core.util.XFormsElement.html;
-import static org.javarosa.core.util.XFormsElement.input;
-import static org.javarosa.core.util.XFormsElement.instance;
-import static org.javarosa.core.util.XFormsElement.item;
-import static org.javarosa.core.util.XFormsElement.mainInstance;
-import static org.javarosa.core.util.XFormsElement.model;
-import static org.javarosa.core.util.XFormsElement.repeat;
-import static org.javarosa.core.util.XFormsElement.select1Dynamic;
-import static org.javarosa.core.util.XFormsElement.t;
-import static org.javarosa.core.util.XFormsElement.title;
-
-import org.javarosa.core.test.Scenario;
+import static org.javarosa.test.BindBuilderXFormsElement.bind;
+import static org.javarosa.test.XFormsElement.body;
+import static org.javarosa.test.XFormsElement.head;
+import static org.javarosa.test.XFormsElement.html;
+import static org.javarosa.test.XFormsElement.input;
+import static org.javarosa.test.XFormsElement.instance;
+import static org.javarosa.test.XFormsElement.item;
+import static org.javarosa.test.XFormsElement.mainInstance;
+import static org.javarosa.test.XFormsElement.model;
+import static org.javarosa.test.XFormsElement.repeat;
+import static org.javarosa.test.XFormsElement.select1Dynamic;
+import static org.javarosa.test.XFormsElement.t;
+import static org.javarosa.test.XFormsElement.title;
+
+import org.javarosa.test.Scenario;
import org.javarosa.measure.Measure;
import org.junit.Test;
diff --git a/src/test/java/org/javarosa/core/model/SelectChoiceTest.java b/src/test/java/org/javarosa/core/model/SelectChoiceTest.java
index 1692f9c9e..14e4307a2 100644
--- a/src/test/java/org/javarosa/core/model/SelectChoiceTest.java
+++ b/src/test/java/org/javarosa/core/model/SelectChoiceTest.java
@@ -23,28 +23,28 @@
import static org.hamcrest.Matchers.is;
import static org.hamcrest.Matchers.nullValue;
import static org.javarosa.core.reference.ReferenceManagerTestUtils.setUpSimpleReferenceManager;
-import static org.javarosa.core.util.BindBuilderXFormsElement.bind;
-import static org.javarosa.core.util.XFormsElement.body;
-import static org.javarosa.core.util.XFormsElement.head;
-import static org.javarosa.core.util.XFormsElement.html;
-import static org.javarosa.core.util.XFormsElement.input;
-import static org.javarosa.core.util.XFormsElement.instance;
-import static org.javarosa.core.util.XFormsElement.item;
-import static org.javarosa.core.util.XFormsElement.label;
-import static org.javarosa.core.util.XFormsElement.mainInstance;
-import static org.javarosa.core.util.XFormsElement.model;
-import static org.javarosa.core.util.XFormsElement.repeat;
-import static org.javarosa.core.util.XFormsElement.select1;
-import static org.javarosa.core.util.XFormsElement.select1Dynamic;
-import static org.javarosa.core.util.XFormsElement.t;
-import static org.javarosa.core.util.XFormsElement.title;
-import static org.javarosa.test.utils.ResourcePathHelper.r;
+import static org.javarosa.test.BindBuilderXFormsElement.bind;
+import static org.javarosa.test.XFormsElement.body;
+import static org.javarosa.test.XFormsElement.head;
+import static org.javarosa.test.XFormsElement.html;
+import static org.javarosa.test.XFormsElement.input;
+import static org.javarosa.test.XFormsElement.instance;
+import static org.javarosa.test.XFormsElement.item;
+import static org.javarosa.test.XFormsElement.label;
+import static org.javarosa.test.XFormsElement.mainInstance;
+import static org.javarosa.test.XFormsElement.model;
+import static org.javarosa.test.XFormsElement.repeat;
+import static org.javarosa.test.XFormsElement.select1;
+import static org.javarosa.test.XFormsElement.select1Dynamic;
+import static org.javarosa.test.XFormsElement.t;
+import static org.javarosa.test.XFormsElement.title;
+import static org.javarosa.test.ResourcePathHelper.r;
import java.io.IOException;
import java.util.List;
import kotlin.Pair;
import org.hamcrest.CoreMatchers;
-import org.javarosa.core.test.Scenario;
+import org.javarosa.test.Scenario;
import org.javarosa.core.util.externalizable.DeserializationException;
import org.javarosa.xform.parse.XFormParser;
import org.junit.Test;
@@ -86,7 +86,7 @@ public void value_should_be_trimmed_when_select_choice_object_constructed() {
@Test
public void getChild_returnsNamedChild_whenChoicesAreFromSecondaryInstance() throws XFormParser.ParseException {
- setUpSimpleReferenceManager(r("external-select-geojson.xml").getParent(), "file");
+ setUpSimpleReferenceManager(r("external-select-geojson.xml").getParentFile(), "file");
Scenario scenario = Scenario.init("external-select-geojson.xml");
assertThat(scenario.choicesOf("/data/q").get(1).getChild("geometry"), CoreMatchers.is("0.5 104 0 0"));
@@ -95,7 +95,7 @@ public void getChild_returnsNamedChild_whenChoicesAreFromSecondaryInstance() thr
@Test
public void getChild_returnsNull_whenChoicesAreFromSecondaryInstance_andRequestedChildDoesNotExist() throws XFormParser.ParseException {
- setUpSimpleReferenceManager(r("external-select-geojson.xml").getParent(), "file");
+ setUpSimpleReferenceManager(r("external-select-geojson.xml").getParentFile(), "file");
Scenario scenario = Scenario.init("external-select-geojson.xml");
assertThat(scenario.choicesOf("/data/q").get(1).getChild("non-existent"), is(nullValue()));
@@ -171,7 +171,7 @@ public void getChild_returnsNull_whenCalledOnAChoiceFromInlineSelect() throws IO
@Test
public void getAdditionalChildren_returnsChildrenInOrder_whenChoicesAreFromSecondaryInstance() throws XFormParser.ParseException {
- setUpSimpleReferenceManager(r("external-select-geojson.xml").getParent(), "file");
+ setUpSimpleReferenceManager(r("external-select-geojson.xml").getParentFile(), "file");
Scenario scenario = Scenario.init("external-select-geojson.xml");
diff --git a/src/test/java/org/javarosa/core/model/SelectMultipleChoiceFilterTest.java b/src/test/java/org/javarosa/core/model/SelectMultipleChoiceFilterTest.java
index 62f686c87..c887a65aa 100644
--- a/src/test/java/org/javarosa/core/model/SelectMultipleChoiceFilterTest.java
+++ b/src/test/java/org/javarosa/core/model/SelectMultipleChoiceFilterTest.java
@@ -7,7 +7,7 @@
import static org.javarosa.core.test.AnswerDataMatchers.answerText;
import static org.javarosa.core.test.SelectChoiceMatchers.choice;
-import org.javarosa.core.test.Scenario;
+import org.javarosa.test.Scenario;
import org.javarosa.xform.parse.XFormParser;
import org.junit.Before;
import org.junit.Test;
diff --git a/src/test/java/org/javarosa/core/model/SelectOneChoiceFilterTest.java b/src/test/java/org/javarosa/core/model/SelectOneChoiceFilterTest.java
index db5a7572e..cb6495ebf 100644
--- a/src/test/java/org/javarosa/core/model/SelectOneChoiceFilterTest.java
+++ b/src/test/java/org/javarosa/core/model/SelectOneChoiceFilterTest.java
@@ -24,7 +24,7 @@
import static org.javarosa.core.test.SelectChoiceMatchers.choice;
import static org.javarosa.form.api.FormEntryController.ANSWER_REQUIRED_BUT_EMPTY;
-import org.javarosa.core.test.Scenario;
+import org.javarosa.test.Scenario;
import org.javarosa.xform.parse.XFormParser;
import org.junit.Assert;
import org.junit.Before;
diff --git a/src/test/java/org/javarosa/core/model/TriggerableDagTest.java b/src/test/java/org/javarosa/core/model/TriggerableDagTest.java
index 5176b11fd..cec3bab4b 100644
--- a/src/test/java/org/javarosa/core/model/TriggerableDagTest.java
+++ b/src/test/java/org/javarosa/core/model/TriggerableDagTest.java
@@ -16,21 +16,21 @@
import static org.javarosa.core.test.QuestionDefMatchers.nonRelevant;
import static org.javarosa.core.test.QuestionDefMatchers.readOnly;
import static org.javarosa.core.test.QuestionDefMatchers.relevant;
-import static org.javarosa.core.test.Scenario.getRef;
-import static org.javarosa.core.util.BindBuilderXFormsElement.bind;
-import static org.javarosa.core.util.XFormsElement.body;
-import static org.javarosa.core.util.XFormsElement.group;
-import static org.javarosa.core.util.XFormsElement.head;
-import static org.javarosa.core.util.XFormsElement.html;
-import static org.javarosa.core.util.XFormsElement.input;
-import static org.javarosa.core.util.XFormsElement.item;
-import static org.javarosa.core.util.XFormsElement.label;
-import static org.javarosa.core.util.XFormsElement.mainInstance;
-import static org.javarosa.core.util.XFormsElement.model;
-import static org.javarosa.core.util.XFormsElement.repeat;
-import static org.javarosa.core.util.XFormsElement.select1;
-import static org.javarosa.core.util.XFormsElement.t;
-import static org.javarosa.core.util.XFormsElement.title;
+import static org.javarosa.test.Scenario.getRef;
+import static org.javarosa.test.BindBuilderXFormsElement.bind;
+import static org.javarosa.test.XFormsElement.body;
+import static org.javarosa.test.XFormsElement.group;
+import static org.javarosa.test.XFormsElement.head;
+import static org.javarosa.test.XFormsElement.html;
+import static org.javarosa.test.XFormsElement.input;
+import static org.javarosa.test.XFormsElement.item;
+import static org.javarosa.test.XFormsElement.label;
+import static org.javarosa.test.XFormsElement.mainInstance;
+import static org.javarosa.test.XFormsElement.model;
+import static org.javarosa.test.XFormsElement.repeat;
+import static org.javarosa.test.XFormsElement.select1;
+import static org.javarosa.test.XFormsElement.t;
+import static org.javarosa.test.XFormsElement.title;
import static org.javarosa.form.api.FormEntryController.ANSWER_CONSTRAINT_VIOLATED;
import static org.javarosa.form.api.FormEntryController.ANSWER_REQUIRED_BUT_EMPTY;
@@ -41,9 +41,9 @@
import java.util.List;
import java.util.stream.Stream;
import org.hamcrest.CoreMatchers;
-import org.javarosa.core.test.Scenario;
-import org.javarosa.core.util.BindBuilderXFormsElement;
-import org.javarosa.core.util.XFormsElement;
+import org.javarosa.test.Scenario;
+import org.javarosa.test.BindBuilderXFormsElement;
+import org.javarosa.test.XFormsElement;
import org.javarosa.debug.Event;
import org.javarosa.form.api.FormEntryController;
import org.javarosa.xform.parse.XFormParseException;
diff --git a/src/test/java/org/javarosa/core/model/actions/InstanceLoadEventsTest.java b/src/test/java/org/javarosa/core/model/actions/InstanceLoadEventsTest.java
index 6a1804f94..690ab926c 100644
--- a/src/test/java/org/javarosa/core/model/actions/InstanceLoadEventsTest.java
+++ b/src/test/java/org/javarosa/core/model/actions/InstanceLoadEventsTest.java
@@ -5,21 +5,21 @@
import static org.hamcrest.Matchers.is;
import static org.javarosa.core.test.AnswerDataMatchers.intAnswer;
import static org.javarosa.core.test.AnswerDataMatchers.stringAnswer;
-import static org.javarosa.core.util.BindBuilderXFormsElement.bind;
-import static org.javarosa.core.util.XFormsElement.body;
-import static org.javarosa.core.util.XFormsElement.head;
-import static org.javarosa.core.util.XFormsElement.html;
-import static org.javarosa.core.util.XFormsElement.input;
-import static org.javarosa.core.util.XFormsElement.mainInstance;
-import static org.javarosa.core.util.XFormsElement.model;
-import static org.javarosa.core.util.XFormsElement.repeat;
-import static org.javarosa.core.util.XFormsElement.setvalue;
-import static org.javarosa.core.util.XFormsElement.t;
-import static org.javarosa.core.util.XFormsElement.title;
+import static org.javarosa.test.BindBuilderXFormsElement.bind;
+import static org.javarosa.test.XFormsElement.body;
+import static org.javarosa.test.XFormsElement.head;
+import static org.javarosa.test.XFormsElement.html;
+import static org.javarosa.test.XFormsElement.input;
+import static org.javarosa.test.XFormsElement.mainInstance;
+import static org.javarosa.test.XFormsElement.model;
+import static org.javarosa.test.XFormsElement.repeat;
+import static org.javarosa.test.XFormsElement.setvalue;
+import static org.javarosa.test.XFormsElement.t;
+import static org.javarosa.test.XFormsElement.title;
import java.io.IOException;
import org.hamcrest.CoreMatchers;
-import org.javarosa.core.test.Scenario;
+import org.javarosa.test.Scenario;
import org.javarosa.xform.parse.XFormParser;
import org.junit.Test;
diff --git a/src/test/java/org/javarosa/core/model/actions/MultipleEventsTest.java b/src/test/java/org/javarosa/core/model/actions/MultipleEventsTest.java
index 92895f4be..6a3e173f9 100644
--- a/src/test/java/org/javarosa/core/model/actions/MultipleEventsTest.java
+++ b/src/test/java/org/javarosa/core/model/actions/MultipleEventsTest.java
@@ -1,6 +1,6 @@
package org.javarosa.core.model.actions;
-import org.javarosa.core.test.Scenario;
+import org.javarosa.test.Scenario;
import org.javarosa.core.util.externalizable.DeserializationException;
import org.javarosa.xform.parse.XFormParseException;
import org.javarosa.xform.parse.XFormParser;
diff --git a/src/test/java/org/javarosa/core/model/actions/OdkNewRepeatEventTest.java b/src/test/java/org/javarosa/core/model/actions/OdkNewRepeatEventTest.java
index bce909be4..3d4371c43 100644
--- a/src/test/java/org/javarosa/core/model/actions/OdkNewRepeatEventTest.java
+++ b/src/test/java/org/javarosa/core/model/actions/OdkNewRepeatEventTest.java
@@ -4,21 +4,21 @@
import static org.hamcrest.Matchers.is;
import static org.hamcrest.Matchers.nullValue;
import static org.javarosa.core.test.AnswerDataMatchers.intAnswer;
-import static org.javarosa.core.util.BindBuilderXFormsElement.bind;
-import static org.javarosa.core.util.XFormsElement.body;
-import static org.javarosa.core.util.XFormsElement.head;
-import static org.javarosa.core.util.XFormsElement.html;
-import static org.javarosa.core.util.XFormsElement.input;
-import static org.javarosa.core.util.XFormsElement.mainInstance;
-import static org.javarosa.core.util.XFormsElement.model;
-import static org.javarosa.core.util.XFormsElement.repeat;
-import static org.javarosa.core.util.XFormsElement.setvalue;
-import static org.javarosa.core.util.XFormsElement.t;
-import static org.javarosa.core.util.XFormsElement.title;
-import static org.javarosa.test.utils.ResourcePathHelper.r;
+import static org.javarosa.test.BindBuilderXFormsElement.bind;
+import static org.javarosa.test.XFormsElement.body;
+import static org.javarosa.test.XFormsElement.head;
+import static org.javarosa.test.XFormsElement.html;
+import static org.javarosa.test.XFormsElement.input;
+import static org.javarosa.test.XFormsElement.mainInstance;
+import static org.javarosa.test.XFormsElement.model;
+import static org.javarosa.test.XFormsElement.repeat;
+import static org.javarosa.test.XFormsElement.setvalue;
+import static org.javarosa.test.XFormsElement.t;
+import static org.javarosa.test.XFormsElement.title;
+import static org.javarosa.test.ResourcePathHelper.r;
import java.io.IOException;
-import org.javarosa.core.test.Scenario;
+import org.javarosa.test.Scenario;
import org.javarosa.xform.parse.XFormParseException;
import org.javarosa.xform.parse.XFormParser;
import org.junit.Test;
diff --git a/src/test/java/org/javarosa/core/model/actions/RecordAudioActionTest.java b/src/test/java/org/javarosa/core/model/actions/RecordAudioActionTest.java
index 286b6ef39..ce7c85290 100644
--- a/src/test/java/org/javarosa/core/model/actions/RecordAudioActionTest.java
+++ b/src/test/java/org/javarosa/core/model/actions/RecordAudioActionTest.java
@@ -18,20 +18,20 @@
import static org.hamcrest.MatcherAssert.assertThat;
import static org.hamcrest.Matchers.is;
-import static org.javarosa.core.test.Scenario.getRef;
-import static org.javarosa.core.util.XFormsElement.body;
-import static org.javarosa.core.util.XFormsElement.head;
-import static org.javarosa.core.util.XFormsElement.html;
-import static org.javarosa.core.util.XFormsElement.input;
-import static org.javarosa.core.util.XFormsElement.mainInstance;
-import static org.javarosa.core.util.XFormsElement.model;
-import static org.javarosa.core.util.XFormsElement.repeat;
-import static org.javarosa.core.util.XFormsElement.t;
-import static org.javarosa.core.util.XFormsElement.title;
+import static org.javarosa.test.Scenario.getRef;
+import static org.javarosa.test.XFormsElement.body;
+import static org.javarosa.test.XFormsElement.head;
+import static org.javarosa.test.XFormsElement.html;
+import static org.javarosa.test.XFormsElement.input;
+import static org.javarosa.test.XFormsElement.mainInstance;
+import static org.javarosa.test.XFormsElement.model;
+import static org.javarosa.test.XFormsElement.repeat;
+import static org.javarosa.test.XFormsElement.t;
+import static org.javarosa.test.XFormsElement.title;
import java.io.IOException;
import org.javarosa.core.model.actions.recordaudio.RecordAudioActions;
-import org.javarosa.core.test.Scenario;
+import org.javarosa.test.Scenario;
import org.javarosa.core.util.externalizable.DeserializationException;
import org.javarosa.xform.parse.XFormParser;
import org.junit.Test;
diff --git a/src/test/java/org/javarosa/core/model/actions/SetGeopointActionTest.java b/src/test/java/org/javarosa/core/model/actions/SetGeopointActionTest.java
index 97f5c708e..e2c97d56d 100644
--- a/src/test/java/org/javarosa/core/model/actions/SetGeopointActionTest.java
+++ b/src/test/java/org/javarosa/core/model/actions/SetGeopointActionTest.java
@@ -19,9 +19,9 @@
import static org.hamcrest.CoreMatchers.equalTo;
import static org.hamcrest.Matchers.is;
import static org.javarosa.core.test.AnswerDataMatchers.stringAnswer;
-import static org.javarosa.core.test.Scenario.getRef;
+import static org.javarosa.test.Scenario.getRef;
import static org.javarosa.core.util.externalizable.ExtUtil.defaultPrototypes;
-import static org.javarosa.test.utils.ResourcePathHelper.r;
+import static org.javarosa.test.ResourcePathHelper.r;
import static org.junit.Assert.assertThat;
import java.io.DataInputStream;
@@ -33,7 +33,7 @@
import org.javarosa.core.model.actions.setgeopoint.SetGeopointAction;
import org.javarosa.core.model.actions.setgeopoint.StubSetGeopointAction;
import org.javarosa.core.model.data.StringData;
-import org.javarosa.core.test.Scenario;
+import org.javarosa.test.Scenario;
import org.javarosa.core.util.externalizable.DeserializationException;
import org.javarosa.xform.parse.XFormParseException;
import org.javarosa.xform.parse.XFormParser;
diff --git a/src/test/java/org/javarosa/core/model/actions/SetValueActionTest.java b/src/test/java/org/javarosa/core/model/actions/SetValueActionTest.java
index 497b92b25..12634a86a 100644
--- a/src/test/java/org/javarosa/core/model/actions/SetValueActionTest.java
+++ b/src/test/java/org/javarosa/core/model/actions/SetValueActionTest.java
@@ -22,23 +22,23 @@
import static org.hamcrest.MatcherAssert.assertThat;
import static org.javarosa.core.test.AnswerDataMatchers.intAnswer;
import static org.javarosa.core.test.AnswerDataMatchers.stringAnswer;
-import static org.javarosa.core.util.BindBuilderXFormsElement.bind;
-import static org.javarosa.core.util.XFormsElement.body;
-import static org.javarosa.core.util.XFormsElement.group;
-import static org.javarosa.core.util.XFormsElement.head;
-import static org.javarosa.core.util.XFormsElement.html;
-import static org.javarosa.core.util.XFormsElement.input;
-import static org.javarosa.core.util.XFormsElement.mainInstance;
-import static org.javarosa.core.util.XFormsElement.model;
-import static org.javarosa.core.util.XFormsElement.repeat;
-import static org.javarosa.core.util.XFormsElement.setvalue;
-import static org.javarosa.core.util.XFormsElement.setvalueLiteral;
-import static org.javarosa.core.util.XFormsElement.t;
-import static org.javarosa.core.util.XFormsElement.title;
+import static org.javarosa.test.BindBuilderXFormsElement.bind;
+import static org.javarosa.test.XFormsElement.body;
+import static org.javarosa.test.XFormsElement.group;
+import static org.javarosa.test.XFormsElement.head;
+import static org.javarosa.test.XFormsElement.html;
+import static org.javarosa.test.XFormsElement.input;
+import static org.javarosa.test.XFormsElement.mainInstance;
+import static org.javarosa.test.XFormsElement.model;
+import static org.javarosa.test.XFormsElement.repeat;
+import static org.javarosa.test.XFormsElement.setvalue;
+import static org.javarosa.test.XFormsElement.setvalueLiteral;
+import static org.javarosa.test.XFormsElement.t;
+import static org.javarosa.test.XFormsElement.title;
import static org.junit.Assert.fail;
import java.io.IOException;
-import org.javarosa.core.test.Scenario;
+import org.javarosa.test.Scenario;
import org.javarosa.core.util.externalizable.DeserializationException;
import org.javarosa.xform.parse.XFormParser;
import org.javarosa.xpath.XPathTypeMismatchException;
diff --git a/src/test/java/org/javarosa/core/model/condition/EvaluationContextExpandReferenceTest.java b/src/test/java/org/javarosa/core/model/condition/EvaluationContextExpandReferenceTest.java
index 677005375..90032f837 100644
--- a/src/test/java/org/javarosa/core/model/condition/EvaluationContextExpandReferenceTest.java
+++ b/src/test/java/org/javarosa/core/model/condition/EvaluationContextExpandReferenceTest.java
@@ -22,22 +22,22 @@
import static org.hamcrest.Matchers.hasItems;
import static org.hamcrest.Matchers.is;
import static org.hamcrest.Matchers.nullValue;
-import static org.javarosa.core.test.Scenario.getRef;
-import static org.javarosa.core.util.BindBuilderXFormsElement.bind;
-import static org.javarosa.core.util.XFormsElement.body;
-import static org.javarosa.core.util.XFormsElement.group;
-import static org.javarosa.core.util.XFormsElement.head;
-import static org.javarosa.core.util.XFormsElement.html;
-import static org.javarosa.core.util.XFormsElement.input;
-import static org.javarosa.core.util.XFormsElement.mainInstance;
-import static org.javarosa.core.util.XFormsElement.model;
-import static org.javarosa.core.util.XFormsElement.repeat;
-import static org.javarosa.core.util.XFormsElement.t;
-import static org.javarosa.core.util.XFormsElement.title;
+import static org.javarosa.test.Scenario.getRef;
+import static org.javarosa.test.BindBuilderXFormsElement.bind;
+import static org.javarosa.test.XFormsElement.body;
+import static org.javarosa.test.XFormsElement.group;
+import static org.javarosa.test.XFormsElement.head;
+import static org.javarosa.test.XFormsElement.html;
+import static org.javarosa.test.XFormsElement.input;
+import static org.javarosa.test.XFormsElement.mainInstance;
+import static org.javarosa.test.XFormsElement.model;
+import static org.javarosa.test.XFormsElement.repeat;
+import static org.javarosa.test.XFormsElement.t;
+import static org.javarosa.test.XFormsElement.title;
import java.io.IOException;
import org.javarosa.core.model.instance.TreeReference;
-import org.javarosa.core.test.Scenario;
+import org.javarosa.test.Scenario;
import org.javarosa.xform.parse.XFormParser;
import org.junit.BeforeClass;
import org.junit.Test;
diff --git a/src/test/java/org/javarosa/core/model/condition/ReadOnlyCalculateTest.java b/src/test/java/org/javarosa/core/model/condition/ReadOnlyCalculateTest.java
index c2b9e8d06..5de0a8d1e 100644
--- a/src/test/java/org/javarosa/core/model/condition/ReadOnlyCalculateTest.java
+++ b/src/test/java/org/javarosa/core/model/condition/ReadOnlyCalculateTest.java
@@ -19,18 +19,18 @@
import static org.hamcrest.CoreMatchers.is;
import static org.hamcrest.MatcherAssert.assertThat;
import static org.javarosa.core.test.AnswerDataMatchers.intAnswer;
-import static org.javarosa.core.util.BindBuilderXFormsElement.bind;
-import static org.javarosa.core.util.XFormsElement.body;
-import static org.javarosa.core.util.XFormsElement.head;
-import static org.javarosa.core.util.XFormsElement.html;
-import static org.javarosa.core.util.XFormsElement.input;
-import static org.javarosa.core.util.XFormsElement.mainInstance;
-import static org.javarosa.core.util.XFormsElement.model;
-import static org.javarosa.core.util.XFormsElement.t;
-import static org.javarosa.core.util.XFormsElement.title;
+import static org.javarosa.test.BindBuilderXFormsElement.bind;
+import static org.javarosa.test.XFormsElement.body;
+import static org.javarosa.test.XFormsElement.head;
+import static org.javarosa.test.XFormsElement.html;
+import static org.javarosa.test.XFormsElement.input;
+import static org.javarosa.test.XFormsElement.mainInstance;
+import static org.javarosa.test.XFormsElement.model;
+import static org.javarosa.test.XFormsElement.t;
+import static org.javarosa.test.XFormsElement.title;
import java.io.IOException;
-import org.javarosa.core.test.Scenario;
+import org.javarosa.test.Scenario;
import org.javarosa.xform.parse.XFormParser;
import org.junit.Test;
diff --git a/src/test/java/org/javarosa/core/model/condition/RecalculateTest.java b/src/test/java/org/javarosa/core/model/condition/RecalculateTest.java
index 96317453d..2321d4094 100644
--- a/src/test/java/org/javarosa/core/model/condition/RecalculateTest.java
+++ b/src/test/java/org/javarosa/core/model/condition/RecalculateTest.java
@@ -1,12 +1,12 @@
package org.javarosa.core.model.condition;
-import static org.javarosa.test.utils.ResourcePathHelper.r;
+import static org.javarosa.test.ResourcePathHelper.r;
import static org.junit.Assert.assertEquals;
import org.javarosa.core.model.FormDef;
import org.javarosa.core.model.FormIndex;
import org.javarosa.core.model.instance.InstanceInitializationFactory;
-import org.javarosa.core.test.FormParseInit;
+import org.javarosa.test.FormParseInit;
import org.javarosa.form.api.FormEntryPrompt;
import org.javarosa.xform.parse.XFormParser;
import org.junit.Before;
diff --git a/src/test/java/org/javarosa/core/model/instance/CsvExternalInstanceTest.java b/src/test/java/org/javarosa/core/model/instance/CsvExternalInstanceTest.java
index 59bf1d571..4803ad0f9 100644
--- a/src/test/java/org/javarosa/core/model/instance/CsvExternalInstanceTest.java
+++ b/src/test/java/org/javarosa/core/model/instance/CsvExternalInstanceTest.java
@@ -9,7 +9,7 @@
import static org.hamcrest.CoreMatchers.is;
import static org.hamcrest.MatcherAssert.assertThat;
-import static org.javarosa.test.utils.ResourcePathHelper.r;
+import static org.javarosa.test.ResourcePathHelper.r;
import static org.junit.Assert.assertEquals;
public class CsvExternalInstanceTest {
@@ -56,7 +56,7 @@ public void missing_fields_replaced_with_spaces() {
@Test
public void ignores_utf8_bom() throws IOException {
- BOMInputStream bomIs = new BOMInputStream(new FileInputStream(r("external-secondary-csv-bom.csv").toFile()));
+ BOMInputStream bomIs = new BOMInputStream(new FileInputStream(r("external-secondary-csv-bom.csv")));
assertThat(bomIs.hasBOM(), is(true));
TreeElement bomCsv = new CsvExternalInstance().parse("id", r("external-secondary-csv-bom.csv").toString());
diff --git a/src/test/java/org/javarosa/core/model/instance/TreeReferenceAnchorHarnessTest.java b/src/test/java/org/javarosa/core/model/instance/TreeReferenceAnchorHarnessTest.java
index 4dc61ccfd..79e084d8b 100644
--- a/src/test/java/org/javarosa/core/model/instance/TreeReferenceAnchorHarnessTest.java
+++ b/src/test/java/org/javarosa/core/model/instance/TreeReferenceAnchorHarnessTest.java
@@ -1,7 +1,7 @@
package org.javarosa.core.model.instance;
import static org.hamcrest.Matchers.is;
-import static org.javarosa.core.test.Scenario.getRef;
+import static org.javarosa.test.Scenario.getRef;
import static org.junit.Assert.assertThat;
import java.util.Arrays;
diff --git a/src/test/java/org/javarosa/core/model/instance/TreeReferenceAnchorTest.java b/src/test/java/org/javarosa/core/model/instance/TreeReferenceAnchorTest.java
index c753eed5e..7d6d85569 100644
--- a/src/test/java/org/javarosa/core/model/instance/TreeReferenceAnchorTest.java
+++ b/src/test/java/org/javarosa/core/model/instance/TreeReferenceAnchorTest.java
@@ -1,7 +1,7 @@
package org.javarosa.core.model.instance;
import static org.hamcrest.Matchers.is;
-import static org.javarosa.core.test.Scenario.getRef;
+import static org.javarosa.test.Scenario.getRef;
import static org.junit.Assert.assertThat;
import org.javarosa.xpath.XPathException;
diff --git a/src/test/java/org/javarosa/core/model/instance/TreeReferenceContextualizeTest.java b/src/test/java/org/javarosa/core/model/instance/TreeReferenceContextualizeTest.java
index 3af23910e..73c44ca79 100644
--- a/src/test/java/org/javarosa/core/model/instance/TreeReferenceContextualizeTest.java
+++ b/src/test/java/org/javarosa/core/model/instance/TreeReferenceContextualizeTest.java
@@ -18,7 +18,7 @@
import static org.hamcrest.Matchers.is;
import static org.hamcrest.Matchers.nullValue;
-import static org.javarosa.core.test.Scenario.getRef;
+import static org.javarosa.test.Scenario.getRef;
import static org.junit.Assert.assertThat;
import java.util.Arrays;
diff --git a/src/test/java/org/javarosa/core/model/instance/TreeReferenceEqualsTest.java b/src/test/java/org/javarosa/core/model/instance/TreeReferenceEqualsTest.java
index a62e0dc16..73e3b64f3 100644
--- a/src/test/java/org/javarosa/core/model/instance/TreeReferenceEqualsTest.java
+++ b/src/test/java/org/javarosa/core/model/instance/TreeReferenceEqualsTest.java
@@ -2,7 +2,7 @@
import static org.hamcrest.MatcherAssert.assertThat;
import static org.hamcrest.Matchers.is;
-import static org.javarosa.core.test.Scenario.getRef;
+import static org.javarosa.test.Scenario.getRef;
import java.util.Arrays;
import java.util.Collection;
diff --git a/src/test/java/org/javarosa/core/model/instance/TreeReferenceGenericizeTest.java b/src/test/java/org/javarosa/core/model/instance/TreeReferenceGenericizeTest.java
index c2376d8a7..18352eaae 100644
--- a/src/test/java/org/javarosa/core/model/instance/TreeReferenceGenericizeTest.java
+++ b/src/test/java/org/javarosa/core/model/instance/TreeReferenceGenericizeTest.java
@@ -18,7 +18,7 @@
import static org.hamcrest.MatcherAssert.assertThat;
import static org.hamcrest.Matchers.is;
-import static org.javarosa.core.test.Scenario.getRef;
+import static org.javarosa.test.Scenario.getRef;
import org.junit.Test;
diff --git a/src/test/java/org/javarosa/core/model/instance/TreeReferenceIsAncestorOfTest.java b/src/test/java/org/javarosa/core/model/instance/TreeReferenceIsAncestorOfTest.java
index 44f0049af..53be5e724 100644
--- a/src/test/java/org/javarosa/core/model/instance/TreeReferenceIsAncestorOfTest.java
+++ b/src/test/java/org/javarosa/core/model/instance/TreeReferenceIsAncestorOfTest.java
@@ -18,7 +18,7 @@
import static org.hamcrest.MatcherAssert.assertThat;
import static org.hamcrest.Matchers.is;
-import static org.javarosa.core.test.Scenario.getRef;
+import static org.javarosa.test.Scenario.getRef;
import java.util.Arrays;
import java.util.Collection;
diff --git a/src/test/java/org/javarosa/core/model/instance/TreeReferenceParentTest.java b/src/test/java/org/javarosa/core/model/instance/TreeReferenceParentTest.java
index 6b8729c43..dbc449a23 100644
--- a/src/test/java/org/javarosa/core/model/instance/TreeReferenceParentTest.java
+++ b/src/test/java/org/javarosa/core/model/instance/TreeReferenceParentTest.java
@@ -2,7 +2,7 @@
import static org.hamcrest.Matchers.is;
import static org.hamcrest.Matchers.nullValue;
-import static org.javarosa.core.test.Scenario.getRef;
+import static org.javarosa.test.Scenario.getRef;
import static org.junit.Assert.assertThat;
import java.util.Arrays;
diff --git a/src/test/java/org/javarosa/core/model/instance/geojson/GeoJsonExternalInstanceTest.java b/src/test/java/org/javarosa/core/model/instance/geojson/GeoJsonExternalInstanceTest.java
index 7ae3cec97..5f5c4fced 100644
--- a/src/test/java/org/javarosa/core/model/instance/geojson/GeoJsonExternalInstanceTest.java
+++ b/src/test/java/org/javarosa/core/model/instance/geojson/GeoJsonExternalInstanceTest.java
@@ -24,7 +24,7 @@
import static org.hamcrest.CoreMatchers.is;
import static org.hamcrest.CoreMatchers.nullValue;
import static org.hamcrest.MatcherAssert.assertThat;
-import static org.javarosa.test.utils.ResourcePathHelper.r;
+import static org.javarosa.test.ResourcePathHelper.r;
import static org.junit.Assert.fail;
public class GeoJsonExternalInstanceTest {
diff --git a/src/test/java/org/javarosa/core/model/instance/test/TreeElementTests.java b/src/test/java/org/javarosa/core/model/instance/test/TreeElementTests.java
index e98f40283..949b949a9 100644
--- a/src/test/java/org/javarosa/core/model/instance/test/TreeElementTests.java
+++ b/src/test/java/org/javarosa/core/model/instance/test/TreeElementTests.java
@@ -1,20 +1,20 @@
package org.javarosa.core.model.instance.test;
-import static org.javarosa.test.utils.ResourcePathHelper.r;
-import static org.junit.Assert.assertEquals;
-import static org.junit.Assert.assertNotNull;
-
-import java.io.IOException;
-import java.nio.file.Files;
-
+import org.apache.commons.io.FileUtils;
import org.javarosa.core.model.FormDef;
import org.javarosa.core.model.instance.TreeElement;
-import org.javarosa.core.test.FormParseInit;
import org.javarosa.form.api.FormEntryController;
+import org.javarosa.test.FormParseInit;
import org.javarosa.xform.parse.XFormParser;
import org.junit.Test;
+import java.io.IOException;
+
+import static org.javarosa.test.ResourcePathHelper.r;
+import static org.junit.Assert.assertEquals;
+import static org.junit.Assert.assertNotNull;
+
public class TreeElementTests {
@Test
@@ -24,7 +24,7 @@ public void testPopulate_withNodesAttributes() throws IOException, XFormParser.P
FormEntryController formEntryController = formParseInit.getFormEntryController();
- byte[] formInstanceAsBytes = Files.readAllBytes(r("populate-nodes-attributes-instance.xml"));
+ byte[] formInstanceAsBytes = FileUtils.readFileToByteArray(r("populate-nodes-attributes-instance.xml"));
TreeElement savedRoot = XFormParser.restoreDataModel(formInstanceAsBytes, null).getRoot();
FormDef formDef = formEntryController.getModel().getForm();
TreeElement dataRootNode = formDef.getInstance().getRoot().deepCopy(true);
diff --git a/src/test/java/org/javarosa/core/model/test/FormDefTest.java b/src/test/java/org/javarosa/core/model/test/FormDefTest.java
index 5eaf83c5a..9bb62a251 100644
--- a/src/test/java/org/javarosa/core/model/test/FormDefTest.java
+++ b/src/test/java/org/javarosa/core/model/test/FormDefTest.java
@@ -19,23 +19,23 @@
import static org.hamcrest.MatcherAssert.assertThat;
import static org.hamcrest.Matchers.is;
import static org.javarosa.core.test.AnswerDataMatchers.stringAnswer;
-import static org.javarosa.core.test.Scenario.AnswerResult.CONSTRAINT_VIOLATED;
-import static org.javarosa.core.test.Scenario.AnswerResult.OK;
-import static org.javarosa.core.test.Scenario.getRef;
-import static org.javarosa.core.util.BindBuilderXFormsElement.bind;
-import static org.javarosa.core.util.XFormsElement.body;
-import static org.javarosa.core.util.XFormsElement.head;
-import static org.javarosa.core.util.XFormsElement.html;
-import static org.javarosa.core.util.XFormsElement.input;
-import static org.javarosa.core.util.XFormsElement.item;
-import static org.javarosa.core.util.XFormsElement.label;
-import static org.javarosa.core.util.XFormsElement.mainInstance;
-import static org.javarosa.core.util.XFormsElement.model;
-import static org.javarosa.core.util.XFormsElement.repeat;
-import static org.javarosa.core.util.XFormsElement.select1;
-import static org.javarosa.core.util.XFormsElement.t;
-import static org.javarosa.core.util.XFormsElement.title;
-import static org.javarosa.test.utils.ResourcePathHelper.r;
+import static org.javarosa.test.Scenario.AnswerResult.CONSTRAINT_VIOLATED;
+import static org.javarosa.test.Scenario.AnswerResult.OK;
+import static org.javarosa.test.Scenario.getRef;
+import static org.javarosa.test.BindBuilderXFormsElement.bind;
+import static org.javarosa.test.XFormsElement.body;
+import static org.javarosa.test.XFormsElement.head;
+import static org.javarosa.test.XFormsElement.html;
+import static org.javarosa.test.XFormsElement.input;
+import static org.javarosa.test.XFormsElement.item;
+import static org.javarosa.test.XFormsElement.label;
+import static org.javarosa.test.XFormsElement.mainInstance;
+import static org.javarosa.test.XFormsElement.model;
+import static org.javarosa.test.XFormsElement.repeat;
+import static org.javarosa.test.XFormsElement.select1;
+import static org.javarosa.test.XFormsElement.t;
+import static org.javarosa.test.XFormsElement.title;
+import static org.javarosa.test.ResourcePathHelper.r;
import java.io.IOException;
import java.util.ArrayList;
@@ -46,8 +46,8 @@
import org.javarosa.core.model.condition.EvaluationContext;
import org.javarosa.core.model.condition.IFunctionHandler;
import org.javarosa.core.model.instance.TreeReference;
-import org.javarosa.core.test.Scenario;
-import org.javarosa.core.util.XFormsElement;
+import org.javarosa.test.Scenario;
+import org.javarosa.test.XFormsElement;
import org.javarosa.form.api.FormEntryCaption;
import org.javarosa.xform.parse.XFormParser;
import org.junit.Test;
diff --git a/src/test/java/org/javarosa/core/model/test/FormIndexSerializationTest.java b/src/test/java/org/javarosa/core/model/test/FormIndexSerializationTest.java
index 95c7f50d1..f7472c873 100644
--- a/src/test/java/org/javarosa/core/model/test/FormIndexSerializationTest.java
+++ b/src/test/java/org/javarosa/core/model/test/FormIndexSerializationTest.java
@@ -1,6 +1,6 @@
package org.javarosa.core.model.test;
-import static org.javarosa.test.utils.ResourcePathHelper.r;
+import static org.javarosa.test.ResourcePathHelper.r;
import static org.junit.Assert.assertEquals;
import java.io.ByteArrayInputStream;
@@ -12,7 +12,7 @@
import org.javarosa.core.model.FormIndex;
import org.javarosa.core.model.instance.TreeReference;
-import org.javarosa.core.test.FormParseInit;
+import org.javarosa.test.FormParseInit;
import org.javarosa.form.api.FormEntryController;
import org.javarosa.xform.parse.XFormParser;
import org.junit.Test;
diff --git a/src/test/java/org/javarosa/core/model/test/QuestionDefTest.java b/src/test/java/org/javarosa/core/model/test/QuestionDefTest.java
index 8dbec4ee6..b4534ab69 100644
--- a/src/test/java/org/javarosa/core/model/test/QuestionDefTest.java
+++ b/src/test/java/org/javarosa/core/model/test/QuestionDefTest.java
@@ -31,7 +31,7 @@
import org.javarosa.core.reference.RootTranslator;
import org.javarosa.core.services.PrototypeManager;
import org.javarosa.core.services.locale.Localizer;
-import org.javarosa.core.test.FormParseInit;
+import org.javarosa.test.FormParseInit;
import org.javarosa.core.util.externalizable.ExtUtil;
import org.javarosa.core.util.externalizable.PrototypeFactory;
import org.javarosa.form.api.FormEntryPrompt;
diff --git a/src/test/java/org/javarosa/core/model/utils/test/QuestionPreloaderTest.java b/src/test/java/org/javarosa/core/model/utils/test/QuestionPreloaderTest.java
index 6339122cd..6414b9b12 100644
--- a/src/test/java/org/javarosa/core/model/utils/test/QuestionPreloaderTest.java
+++ b/src/test/java/org/javarosa/core/model/utils/test/QuestionPreloaderTest.java
@@ -3,18 +3,18 @@
import static org.hamcrest.CoreMatchers.is;
import static org.hamcrest.CoreMatchers.startsWith;
import static org.hamcrest.MatcherAssert.assertThat;
-import static org.javarosa.core.util.BindBuilderXFormsElement.bind;
-import static org.javarosa.core.util.XFormsElement.body;
-import static org.javarosa.core.util.XFormsElement.head;
-import static org.javarosa.core.util.XFormsElement.html;
-import static org.javarosa.core.util.XFormsElement.input;
-import static org.javarosa.core.util.XFormsElement.mainInstance;
-import static org.javarosa.core.util.XFormsElement.model;
-import static org.javarosa.core.util.XFormsElement.t;
-import static org.javarosa.core.util.XFormsElement.title;
+import static org.javarosa.test.BindBuilderXFormsElement.bind;
+import static org.javarosa.test.XFormsElement.body;
+import static org.javarosa.test.XFormsElement.head;
+import static org.javarosa.test.XFormsElement.html;
+import static org.javarosa.test.XFormsElement.input;
+import static org.javarosa.test.XFormsElement.mainInstance;
+import static org.javarosa.test.XFormsElement.model;
+import static org.javarosa.test.XFormsElement.t;
+import static org.javarosa.test.XFormsElement.title;
import java.io.IOException;
-import org.javarosa.core.test.Scenario;
+import org.javarosa.test.Scenario;
import org.javarosa.xform.parse.XFormParser;
import org.junit.Test;
diff --git a/src/test/java/org/javarosa/core/reference/ReferenceManagerTestUtils.java b/src/test/java/org/javarosa/core/reference/ReferenceManagerTestUtils.java
index 204c0d2fe..e099c8bdc 100644
--- a/src/test/java/org/javarosa/core/reference/ReferenceManagerTestUtils.java
+++ b/src/test/java/org/javarosa/core/reference/ReferenceManagerTestUtils.java
@@ -1,6 +1,6 @@
package org.javarosa.core.reference;
-import java.nio.file.Path;
+import java.io.File;
public class ReferenceManagerTestUtils {
/**
@@ -23,14 +23,14 @@ protected Reference factory(String terminal, String URI) {
* Please, be aware that this method resets the singleton ReferenceManager, which could
* have unintended consequences for other classes using it during the same JVM session.
*/
- public static ReferenceManager setUpSimpleReferenceManager(Path path, String... schemes) {
+ public static ReferenceManager setUpSimpleReferenceManager(File file, String... schemes) {
ReferenceManager refManager = ReferenceManager.instance();
refManager.reset();
for (String scheme : schemes) {
refManager.addReferenceFactory(buildReferenceFactory(
scheme,
- path.toAbsolutePath().toString()
+ file.getAbsolutePath()
));
}
return refManager;
diff --git a/src/test/java/org/javarosa/core/util/GeoAreaTest.java b/src/test/java/org/javarosa/core/util/GeoAreaTest.java
index 22ee67518..3f846dcac 100644
--- a/src/test/java/org/javarosa/core/util/GeoAreaTest.java
+++ b/src/test/java/org/javarosa/core/util/GeoAreaTest.java
@@ -18,20 +18,20 @@
import static org.hamcrest.CoreMatchers.is;
import static org.hamcrest.number.IsCloseTo.closeTo;
-import static org.javarosa.core.util.BindBuilderXFormsElement.bind;
-import static org.javarosa.core.util.XFormsElement.body;
-import static org.javarosa.core.util.XFormsElement.head;
-import static org.javarosa.core.util.XFormsElement.html;
-import static org.javarosa.core.util.XFormsElement.input;
-import static org.javarosa.core.util.XFormsElement.mainInstance;
-import static org.javarosa.core.util.XFormsElement.model;
-import static org.javarosa.core.util.XFormsElement.repeat;
-import static org.javarosa.core.util.XFormsElement.t;
-import static org.javarosa.core.util.XFormsElement.title;
+import static org.javarosa.test.BindBuilderXFormsElement.bind;
+import static org.javarosa.test.XFormsElement.body;
+import static org.javarosa.test.XFormsElement.head;
+import static org.javarosa.test.XFormsElement.html;
+import static org.javarosa.test.XFormsElement.input;
+import static org.javarosa.test.XFormsElement.mainInstance;
+import static org.javarosa.test.XFormsElement.model;
+import static org.javarosa.test.XFormsElement.repeat;
+import static org.javarosa.test.XFormsElement.t;
+import static org.javarosa.test.XFormsElement.title;
import static org.junit.Assert.assertThat;
import java.io.IOException;
-import org.javarosa.core.test.Scenario;
+import org.javarosa.test.Scenario;
import org.javarosa.xform.parse.XFormParser;
import org.junit.Test;
diff --git a/src/test/java/org/javarosa/core/util/GeoDistanceTest.java b/src/test/java/org/javarosa/core/util/GeoDistanceTest.java
index b97eb1a4d..d5a1692ec 100644
--- a/src/test/java/org/javarosa/core/util/GeoDistanceTest.java
+++ b/src/test/java/org/javarosa/core/util/GeoDistanceTest.java
@@ -21,22 +21,22 @@
import static org.hamcrest.CoreMatchers.is;
import static org.hamcrest.MatcherAssert.assertThat;
import static org.hamcrest.Matchers.closeTo;
-import static org.javarosa.core.util.BindBuilderXFormsElement.bind;
+import static org.javarosa.test.BindBuilderXFormsElement.bind;
import static org.javarosa.core.util.GeoUtils.EARTH_EQUATORIAL_CIRCUMFERENCE_METERS;
-import static org.javarosa.core.util.XFormsElement.body;
-import static org.javarosa.core.util.XFormsElement.head;
-import static org.javarosa.core.util.XFormsElement.html;
-import static org.javarosa.core.util.XFormsElement.input;
-import static org.javarosa.core.util.XFormsElement.mainInstance;
-import static org.javarosa.core.util.XFormsElement.model;
-import static org.javarosa.core.util.XFormsElement.repeat;
-import static org.javarosa.core.util.XFormsElement.t;
-import static org.javarosa.core.util.XFormsElement.title;
+import static org.javarosa.test.XFormsElement.body;
+import static org.javarosa.test.XFormsElement.head;
+import static org.javarosa.test.XFormsElement.html;
+import static org.javarosa.test.XFormsElement.input;
+import static org.javarosa.test.XFormsElement.mainInstance;
+import static org.javarosa.test.XFormsElement.model;
+import static org.javarosa.test.XFormsElement.repeat;
+import static org.javarosa.test.XFormsElement.t;
+import static org.javarosa.test.XFormsElement.title;
import static org.junit.Assert.fail;
import java.io.IOException;
import org.hamcrest.number.IsCloseTo;
-import org.javarosa.core.test.Scenario;
+import org.javarosa.test.Scenario;
import org.javarosa.xform.parse.XFormParser;
import org.javarosa.xpath.XPathTypeMismatchException;
import org.junit.Test;
diff --git a/src/test/java/org/javarosa/entities/EntitiesTest.java b/src/test/java/org/javarosa/entities/EntitiesTest.java
index 7675b0844..d1e714a59 100644
--- a/src/test/java/org/javarosa/entities/EntitiesTest.java
+++ b/src/test/java/org/javarosa/entities/EntitiesTest.java
@@ -2,8 +2,8 @@
import kotlin.Pair;
import org.javarosa.core.model.instance.TreeElement;
-import org.javarosa.core.test.Scenario;
-import org.javarosa.core.util.XFormsElement;
+import org.javarosa.test.Scenario;
+import org.javarosa.test.XFormsElement;
import org.javarosa.core.util.externalizable.DeserializationException;
import org.javarosa.entities.internal.Entities;
import org.javarosa.xform.parse.XFormParser;
@@ -20,17 +20,17 @@
import static org.hamcrest.MatcherAssert.assertThat;
import static org.hamcrest.Matchers.equalTo;
import static org.hamcrest.Matchers.is;
-import static org.javarosa.core.util.BindBuilderXFormsElement.bind;
-import static org.javarosa.core.util.XFormsElement.body;
-import static org.javarosa.core.util.XFormsElement.head;
-import static org.javarosa.core.util.XFormsElement.input;
-import static org.javarosa.core.util.XFormsElement.item;
-import static org.javarosa.core.util.XFormsElement.mainInstance;
-import static org.javarosa.core.util.XFormsElement.model;
-import static org.javarosa.core.util.XFormsElement.select1;
-import static org.javarosa.core.util.XFormsElement.setvalue;
-import static org.javarosa.core.util.XFormsElement.t;
-import static org.javarosa.core.util.XFormsElement.title;
+import static org.javarosa.test.BindBuilderXFormsElement.bind;
+import static org.javarosa.test.XFormsElement.body;
+import static org.javarosa.test.XFormsElement.head;
+import static org.javarosa.test.XFormsElement.input;
+import static org.javarosa.test.XFormsElement.item;
+import static org.javarosa.test.XFormsElement.mainInstance;
+import static org.javarosa.test.XFormsElement.model;
+import static org.javarosa.test.XFormsElement.select1;
+import static org.javarosa.test.XFormsElement.setvalue;
+import static org.javarosa.test.XFormsElement.t;
+import static org.javarosa.test.XFormsElement.title;
public class EntitiesTest {
diff --git a/src/test/java/org/javarosa/entities/EntityFormFinalizationProcessorTest.java b/src/test/java/org/javarosa/entities/EntityFormFinalizationProcessorTest.java
index 8006690e3..13c92cef2 100644
--- a/src/test/java/org/javarosa/entities/EntityFormFinalizationProcessorTest.java
+++ b/src/test/java/org/javarosa/entities/EntityFormFinalizationProcessorTest.java
@@ -1,7 +1,7 @@
package org.javarosa.entities;
-import org.javarosa.core.test.Scenario;
-import org.javarosa.core.util.XFormsElement;
+import org.javarosa.test.Scenario;
+import org.javarosa.test.XFormsElement;
import org.javarosa.entities.internal.Entities;
import org.javarosa.form.api.FormEntryModel;
import org.javarosa.xform.parse.XFormParserFactory;
@@ -12,14 +12,14 @@
import static org.hamcrest.MatcherAssert.assertThat;
import static org.hamcrest.Matchers.equalTo;
-import static org.javarosa.core.util.BindBuilderXFormsElement.bind;
-import static org.javarosa.core.util.XFormsElement.body;
-import static org.javarosa.core.util.XFormsElement.head;
-import static org.javarosa.core.util.XFormsElement.input;
-import static org.javarosa.core.util.XFormsElement.mainInstance;
-import static org.javarosa.core.util.XFormsElement.model;
-import static org.javarosa.core.util.XFormsElement.t;
-import static org.javarosa.core.util.XFormsElement.title;
+import static org.javarosa.test.BindBuilderXFormsElement.bind;
+import static org.javarosa.test.XFormsElement.body;
+import static org.javarosa.test.XFormsElement.head;
+import static org.javarosa.test.XFormsElement.input;
+import static org.javarosa.test.XFormsElement.mainInstance;
+import static org.javarosa.test.XFormsElement.model;
+import static org.javarosa.test.XFormsElement.t;
+import static org.javarosa.test.XFormsElement.title;
public class EntityFormFinalizationProcessorTest {
diff --git a/src/test/java/org/javarosa/entities/internal/EntityFormParseProcessorTest.java b/src/test/java/org/javarosa/entities/internal/EntityFormParseProcessorTest.java
index 2566ec736..146dba043 100644
--- a/src/test/java/org/javarosa/entities/internal/EntityFormParseProcessorTest.java
+++ b/src/test/java/org/javarosa/entities/internal/EntityFormParseProcessorTest.java
@@ -2,7 +2,7 @@
import kotlin.Pair;
import org.javarosa.core.model.FormDef;
-import org.javarosa.core.util.XFormsElement;
+import org.javarosa.test.XFormsElement;
import org.javarosa.entities.UnrecognizedEntityVersionException;
import org.javarosa.xform.parse.XFormParser;
import org.javarosa.xform.parse.XFormParser.MissingModelAttributeException;
@@ -18,14 +18,14 @@
import static org.hamcrest.Matchers.instanceOf;
import static org.hamcrest.Matchers.is;
import static org.hamcrest.Matchers.notNullValue;
-import static org.javarosa.core.util.BindBuilderXFormsElement.bind;
-import static org.javarosa.core.util.XFormsElement.body;
-import static org.javarosa.core.util.XFormsElement.head;
-import static org.javarosa.core.util.XFormsElement.input;
-import static org.javarosa.core.util.XFormsElement.mainInstance;
-import static org.javarosa.core.util.XFormsElement.model;
-import static org.javarosa.core.util.XFormsElement.t;
-import static org.javarosa.core.util.XFormsElement.title;
+import static org.javarosa.test.BindBuilderXFormsElement.bind;
+import static org.javarosa.test.XFormsElement.body;
+import static org.javarosa.test.XFormsElement.head;
+import static org.javarosa.test.XFormsElement.input;
+import static org.javarosa.test.XFormsElement.mainInstance;
+import static org.javarosa.test.XFormsElement.model;
+import static org.javarosa.test.XFormsElement.t;
+import static org.javarosa.test.XFormsElement.title;
import static org.junit.Assert.fail;
public class EntityFormParseProcessorTest {
diff --git a/src/test/java/org/javarosa/form/api/ConstraintTextTest.java b/src/test/java/org/javarosa/form/api/ConstraintTextTest.java
index 1fcbe7b2e..51817d0fb 100644
--- a/src/test/java/org/javarosa/form/api/ConstraintTextTest.java
+++ b/src/test/java/org/javarosa/form/api/ConstraintTextTest.java
@@ -16,10 +16,10 @@
package org.javarosa.form.api;
-import static org.javarosa.test.utils.ResourcePathHelper.r;
+import static org.javarosa.test.ResourcePathHelper.r;
import static org.junit.Assert.assertEquals;
import org.javarosa.core.model.FormDef;
-import org.javarosa.core.test.FormParseInit;
+import org.javarosa.test.FormParseInit;
import org.javarosa.xform.parse.XFormParser;
import org.junit.Test;
diff --git a/src/test/java/org/javarosa/form/api/FormEntryControllerTest.java b/src/test/java/org/javarosa/form/api/FormEntryControllerTest.java
index de074172b..bf42f3c8c 100644
--- a/src/test/java/org/javarosa/form/api/FormEntryControllerTest.java
+++ b/src/test/java/org/javarosa/form/api/FormEntryControllerTest.java
@@ -2,23 +2,23 @@
import static org.hamcrest.MatcherAssert.assertThat;
import static org.hamcrest.Matchers.is;
-import static org.javarosa.core.test.Scenario.getRef;
-import static org.javarosa.core.util.BindBuilderXFormsElement.bind;
-import static org.javarosa.core.util.XFormsElement.body;
-import static org.javarosa.core.util.XFormsElement.group;
-import static org.javarosa.core.util.XFormsElement.head;
-import static org.javarosa.core.util.XFormsElement.html;
-import static org.javarosa.core.util.XFormsElement.input;
-import static org.javarosa.core.util.XFormsElement.mainInstance;
-import static org.javarosa.core.util.XFormsElement.model;
-import static org.javarosa.core.util.XFormsElement.repeat;
-import static org.javarosa.core.util.XFormsElement.t;
-import static org.javarosa.core.util.XFormsElement.title;
+import static org.javarosa.test.Scenario.getRef;
+import static org.javarosa.test.BindBuilderXFormsElement.bind;
+import static org.javarosa.test.XFormsElement.body;
+import static org.javarosa.test.XFormsElement.group;
+import static org.javarosa.test.XFormsElement.head;
+import static org.javarosa.test.XFormsElement.html;
+import static org.javarosa.test.XFormsElement.input;
+import static org.javarosa.test.XFormsElement.mainInstance;
+import static org.javarosa.test.XFormsElement.model;
+import static org.javarosa.test.XFormsElement.repeat;
+import static org.javarosa.test.XFormsElement.t;
+import static org.javarosa.test.XFormsElement.title;
import static org.javarosa.form.api.FormEntryController.EVENT_GROUP;
import static org.javarosa.form.api.FormEntryController.EVENT_QUESTION;
import static org.javarosa.form.api.FormEntryController.EVENT_REPEAT;
-import org.javarosa.core.test.Scenario;
+import org.javarosa.test.Scenario;
import org.junit.Test;
public class FormEntryControllerTest {
diff --git a/src/test/java/org/javarosa/form/api/FormEntryModelTest.java b/src/test/java/org/javarosa/form/api/FormEntryModelTest.java
index 6f2967478..17f861c7e 100644
--- a/src/test/java/org/javarosa/form/api/FormEntryModelTest.java
+++ b/src/test/java/org/javarosa/form/api/FormEntryModelTest.java
@@ -17,22 +17,22 @@
package org.javarosa.form.api;
import static org.hamcrest.Matchers.is;
-import static org.javarosa.core.util.BindBuilderXFormsElement.bind;
-import static org.javarosa.core.util.XFormsElement.body;
-import static org.javarosa.core.util.XFormsElement.group;
-import static org.javarosa.core.util.XFormsElement.head;
-import static org.javarosa.core.util.XFormsElement.html;
-import static org.javarosa.core.util.XFormsElement.input;
-import static org.javarosa.core.util.XFormsElement.mainInstance;
-import static org.javarosa.core.util.XFormsElement.model;
-import static org.javarosa.core.util.XFormsElement.t;
-import static org.javarosa.core.util.XFormsElement.title;
+import static org.javarosa.test.BindBuilderXFormsElement.bind;
+import static org.javarosa.test.XFormsElement.body;
+import static org.javarosa.test.XFormsElement.group;
+import static org.javarosa.test.XFormsElement.head;
+import static org.javarosa.test.XFormsElement.html;
+import static org.javarosa.test.XFormsElement.input;
+import static org.javarosa.test.XFormsElement.mainInstance;
+import static org.javarosa.test.XFormsElement.model;
+import static org.javarosa.test.XFormsElement.t;
+import static org.javarosa.test.XFormsElement.title;
import static org.junit.Assert.assertThat;
import java.io.IOException;
import org.javarosa.core.model.FormDef;
import org.javarosa.core.model.FormIndex;
-import org.javarosa.core.test.Scenario;
+import org.javarosa.test.Scenario;
import org.javarosa.xform.parse.XFormParser;
import org.junit.Test;
diff --git a/src/test/java/org/javarosa/form/api/FormEntryPromptTest.java b/src/test/java/org/javarosa/form/api/FormEntryPromptTest.java
index a13e77290..a380a65c8 100644
--- a/src/test/java/org/javarosa/form/api/FormEntryPromptTest.java
+++ b/src/test/java/org/javarosa/form/api/FormEntryPromptTest.java
@@ -18,21 +18,21 @@
import static org.hamcrest.MatcherAssert.assertThat;
import static org.hamcrest.Matchers.is;
-import static org.javarosa.core.util.XFormsElement.body;
-import static org.javarosa.core.util.XFormsElement.head;
-import static org.javarosa.core.util.XFormsElement.html;
-import static org.javarosa.core.util.XFormsElement.input;
-import static org.javarosa.core.util.XFormsElement.instance;
-import static org.javarosa.core.util.XFormsElement.item;
-import static org.javarosa.core.util.XFormsElement.mainInstance;
-import static org.javarosa.core.util.XFormsElement.model;
-import static org.javarosa.core.util.XFormsElement.repeat;
-import static org.javarosa.core.util.XFormsElement.select1Dynamic;
-import static org.javarosa.core.util.XFormsElement.t;
-import static org.javarosa.core.util.XFormsElement.title;
+import static org.javarosa.test.XFormsElement.body;
+import static org.javarosa.test.XFormsElement.head;
+import static org.javarosa.test.XFormsElement.html;
+import static org.javarosa.test.XFormsElement.input;
+import static org.javarosa.test.XFormsElement.instance;
+import static org.javarosa.test.XFormsElement.item;
+import static org.javarosa.test.XFormsElement.mainInstance;
+import static org.javarosa.test.XFormsElement.model;
+import static org.javarosa.test.XFormsElement.repeat;
+import static org.javarosa.test.XFormsElement.select1Dynamic;
+import static org.javarosa.test.XFormsElement.t;
+import static org.javarosa.test.XFormsElement.title;
import java.io.IOException;
-import org.javarosa.core.test.Scenario;
+import org.javarosa.test.Scenario;
import org.javarosa.xform.parse.XFormParser;
import org.junit.Test;
diff --git a/src/test/java/org/javarosa/form/api/FormNavigationTestCase.java b/src/test/java/org/javarosa/form/api/FormNavigationTestCase.java
index 910b6028d..195fbe84f 100644
--- a/src/test/java/org/javarosa/form/api/FormNavigationTestCase.java
+++ b/src/test/java/org/javarosa/form/api/FormNavigationTestCase.java
@@ -1,6 +1,6 @@
package org.javarosa.form.api;
-import org.javarosa.core.test.FormParseInit;
+import org.javarosa.test.FormParseInit;
import org.javarosa.xform.parse.XFormParser;
import org.junit.Test;
import org.junit.runner.RunWith;
@@ -9,7 +9,7 @@
import java.util.Arrays;
import static org.javarosa.form.api.FormEntryController.EVENT_PROMPT_NEW_REPEAT;
-import static org.javarosa.test.utils.ResourcePathHelper.r;
+import static org.javarosa.test.ResourcePathHelper.r;
import static org.junit.Assert.assertEquals;
@RunWith(Parameterized.class)
diff --git a/src/test/java/org/javarosa/form/api/MultiplePredicateTest.java b/src/test/java/org/javarosa/form/api/MultiplePredicateTest.java
index d3a100d34..237a3cb2c 100644
--- a/src/test/java/org/javarosa/form/api/MultiplePredicateTest.java
+++ b/src/test/java/org/javarosa/form/api/MultiplePredicateTest.java
@@ -1,21 +1,21 @@
package org.javarosa.form.api;
-import org.javarosa.core.test.Scenario;
+import org.javarosa.test.Scenario;
import org.junit.Test;
import static org.hamcrest.MatcherAssert.assertThat;
import static org.hamcrest.Matchers.equalTo;
import static org.hamcrest.Matchers.nullValue;
-import static org.javarosa.core.util.BindBuilderXFormsElement.bind;
-import static org.javarosa.core.util.XFormsElement.body;
-import static org.javarosa.core.util.XFormsElement.head;
-import static org.javarosa.core.util.XFormsElement.html;
-import static org.javarosa.core.util.XFormsElement.input;
-import static org.javarosa.core.util.XFormsElement.instance;
-import static org.javarosa.core.util.XFormsElement.mainInstance;
-import static org.javarosa.core.util.XFormsElement.model;
-import static org.javarosa.core.util.XFormsElement.t;
-import static org.javarosa.core.util.XFormsElement.title;
+import static org.javarosa.test.BindBuilderXFormsElement.bind;
+import static org.javarosa.test.XFormsElement.body;
+import static org.javarosa.test.XFormsElement.head;
+import static org.javarosa.test.XFormsElement.html;
+import static org.javarosa.test.XFormsElement.input;
+import static org.javarosa.test.XFormsElement.instance;
+import static org.javarosa.test.XFormsElement.mainInstance;
+import static org.javarosa.test.XFormsElement.model;
+import static org.javarosa.test.XFormsElement.t;
+import static org.javarosa.test.XFormsElement.title;
public class MultiplePredicateTest {
diff --git a/src/test/java/org/javarosa/model/xform/CompactSerializingVisitorTest.java b/src/test/java/org/javarosa/model/xform/CompactSerializingVisitorTest.java
index 1cb951e01..56a739921 100644
--- a/src/test/java/org/javarosa/model/xform/CompactSerializingVisitorTest.java
+++ b/src/test/java/org/javarosa/model/xform/CompactSerializingVisitorTest.java
@@ -3,7 +3,7 @@
import org.javarosa.core.model.instance.FormInstance;
import org.javarosa.core.model.instance.TreeElement;
import org.javarosa.core.services.transport.payload.ByteArrayPayload;
-import org.javarosa.core.test.FormParseInit;
+import org.javarosa.test.FormParseInit;
import org.javarosa.form.api.FormEntryController;
import org.javarosa.xform.parse.XFormParser;
import org.junit.Before;
@@ -11,7 +11,7 @@
import java.io.IOException;
-import static org.javarosa.test.utils.ResourcePathHelper.r;
+import static org.javarosa.test.ResourcePathHelper.r;
import static org.javarosa.xform.parse.XFormParser.NAMESPACE_ODK;
import static org.junit.Assert.assertEquals;
import static org.junit.Assert.assertFalse;
diff --git a/src/test/java/org/javarosa/model/xform/XFormSerializingVisitorTest.java b/src/test/java/org/javarosa/model/xform/XFormSerializingVisitorTest.java
index 06013619b..4d05b9a96 100644
--- a/src/test/java/org/javarosa/model/xform/XFormSerializingVisitorTest.java
+++ b/src/test/java/org/javarosa/model/xform/XFormSerializingVisitorTest.java
@@ -1,7 +1,7 @@
package org.javarosa.model.xform;
-import org.javarosa.core.test.Scenario;
-import org.javarosa.core.util.XFormsElement;
+import org.javarosa.test.Scenario;
+import org.javarosa.test.XFormsElement;
import org.javarosa.xform.parse.XFormParser;
import org.junit.Test;
@@ -9,15 +9,15 @@
import static org.hamcrest.MatcherAssert.assertThat;
import static org.hamcrest.Matchers.containsString;
-import static org.javarosa.core.util.BindBuilderXFormsElement.bind;
-import static org.javarosa.core.util.XFormsElement.body;
-import static org.javarosa.core.util.XFormsElement.head;
-import static org.javarosa.core.util.XFormsElement.html;
-import static org.javarosa.core.util.XFormsElement.input;
-import static org.javarosa.core.util.XFormsElement.mainInstance;
-import static org.javarosa.core.util.XFormsElement.model;
-import static org.javarosa.core.util.XFormsElement.t;
-import static org.javarosa.core.util.XFormsElement.title;
+import static org.javarosa.test.BindBuilderXFormsElement.bind;
+import static org.javarosa.test.XFormsElement.body;
+import static org.javarosa.test.XFormsElement.head;
+import static org.javarosa.test.XFormsElement.html;
+import static org.javarosa.test.XFormsElement.input;
+import static org.javarosa.test.XFormsElement.mainInstance;
+import static org.javarosa.test.XFormsElement.model;
+import static org.javarosa.test.XFormsElement.t;
+import static org.javarosa.test.XFormsElement.title;
public class XFormSerializingVisitorTest {
diff --git a/src/test/java/org/javarosa/regression/IndexedRepeatRelativeRefsTest.java b/src/test/java/org/javarosa/regression/IndexedRepeatRelativeRefsTest.java
index 95d63e27c..35b4b4e64 100644
--- a/src/test/java/org/javarosa/regression/IndexedRepeatRelativeRefsTest.java
+++ b/src/test/java/org/javarosa/regression/IndexedRepeatRelativeRefsTest.java
@@ -18,22 +18,22 @@
import static org.hamcrest.Matchers.is;
import static org.javarosa.core.test.AnswerDataMatchers.intAnswer;
-import static org.javarosa.core.util.BindBuilderXFormsElement.bind;
-import static org.javarosa.core.util.XFormsElement.body;
-import static org.javarosa.core.util.XFormsElement.group;
-import static org.javarosa.core.util.XFormsElement.head;
-import static org.javarosa.core.util.XFormsElement.html;
-import static org.javarosa.core.util.XFormsElement.input;
-import static org.javarosa.core.util.XFormsElement.mainInstance;
-import static org.javarosa.core.util.XFormsElement.model;
-import static org.javarosa.core.util.XFormsElement.repeat;
-import static org.javarosa.core.util.XFormsElement.t;
-import static org.javarosa.core.util.XFormsElement.title;
+import static org.javarosa.test.BindBuilderXFormsElement.bind;
+import static org.javarosa.test.XFormsElement.body;
+import static org.javarosa.test.XFormsElement.group;
+import static org.javarosa.test.XFormsElement.head;
+import static org.javarosa.test.XFormsElement.html;
+import static org.javarosa.test.XFormsElement.input;
+import static org.javarosa.test.XFormsElement.mainInstance;
+import static org.javarosa.test.XFormsElement.model;
+import static org.javarosa.test.XFormsElement.repeat;
+import static org.javarosa.test.XFormsElement.t;
+import static org.javarosa.test.XFormsElement.title;
import static org.junit.Assert.assertThat;
import java.io.IOException;
import java.util.Arrays;
-import org.javarosa.core.test.Scenario;
+import org.javarosa.test.Scenario;
import org.javarosa.xform.parse.XFormParser;
import org.junit.Test;
import org.junit.runner.RunWith;
diff --git a/src/test/java/org/javarosa/regression/SameRefDifferentInstancesIssue449Test.java b/src/test/java/org/javarosa/regression/SameRefDifferentInstancesIssue449Test.java
index 66e02c360..cac6fbf17 100644
--- a/src/test/java/org/javarosa/regression/SameRefDifferentInstancesIssue449Test.java
+++ b/src/test/java/org/javarosa/regression/SameRefDifferentInstancesIssue449Test.java
@@ -16,35 +16,36 @@
package org.javarosa.regression;
-import static org.hamcrest.Matchers.is;
-import static org.javarosa.core.test.AnswerDataMatchers.stringAnswer;
-import static org.javarosa.core.util.BindBuilderXFormsElement.bind;
-import static org.javarosa.core.util.XFormsElement.body;
-import static org.javarosa.core.util.XFormsElement.head;
-import static org.javarosa.core.util.XFormsElement.html;
-import static org.javarosa.core.util.XFormsElement.input;
-import static org.javarosa.core.util.XFormsElement.mainInstance;
-import static org.javarosa.core.util.XFormsElement.model;
-import static org.javarosa.core.util.XFormsElement.t;
-import static org.javarosa.core.util.XFormsElement.title;
-import static org.javarosa.test.utils.ResourcePathHelper.r;
-import static org.junit.Assert.assertThat;
-
-import java.io.IOException;
-import java.nio.file.Path;
import org.hamcrest.CoreMatchers;
import org.hamcrest.MatcherAssert;
import org.javarosa.core.reference.ReferenceManagerTestUtils;
-import org.javarosa.core.test.Scenario;
import org.javarosa.core.util.externalizable.DeserializationException;
+import org.javarosa.test.Scenario;
import org.javarosa.xform.parse.XFormParser;
import org.junit.Test;
+import java.io.File;
+import java.io.IOException;
+
+import static org.hamcrest.Matchers.is;
+import static org.javarosa.core.test.AnswerDataMatchers.stringAnswer;
+import static org.javarosa.test.BindBuilderXFormsElement.bind;
+import static org.javarosa.test.ResourcePathHelper.r;
+import static org.javarosa.test.XFormsElement.body;
+import static org.javarosa.test.XFormsElement.head;
+import static org.javarosa.test.XFormsElement.html;
+import static org.javarosa.test.XFormsElement.input;
+import static org.javarosa.test.XFormsElement.mainInstance;
+import static org.javarosa.test.XFormsElement.model;
+import static org.javarosa.test.XFormsElement.t;
+import static org.javarosa.test.XFormsElement.title;
+import static org.junit.Assert.assertThat;
+
public class SameRefDifferentInstancesIssue449Test {
@Test
public void formWithSameRefInDifferentInstances_isSuccessfullyDeserialized() throws IOException, DeserializationException, XFormParser.ParseException {
- Path formFile = r("issue_449.xml");
- ReferenceManagerTestUtils.setUpSimpleReferenceManager(formFile.getParent(), "file");
+ File formFile = r("issue_449.xml");
+ ReferenceManagerTestUtils.setUpSimpleReferenceManager(formFile.getParentFile(), "file");
Scenario scenario = Scenario.init(formFile);
scenario.answer("/data/new-part", "c");
diff --git a/src/test/java/org/javarosa/regression/TriggersForRelativeRefsTest.java b/src/test/java/org/javarosa/regression/TriggersForRelativeRefsTest.java
index d8b061581..041b8c05c 100644
--- a/src/test/java/org/javarosa/regression/TriggersForRelativeRefsTest.java
+++ b/src/test/java/org/javarosa/regression/TriggersForRelativeRefsTest.java
@@ -1,6 +1,6 @@
package org.javarosa.regression;
-import org.javarosa.core.test.Scenario;
+import org.javarosa.test.Scenario;
import org.javarosa.xform.parse.XFormParser;
import org.junit.Test;
@@ -11,16 +11,16 @@
import static org.hamcrest.CoreMatchers.is;
import static org.javarosa.core.test.AnswerDataMatchers.intAnswer;
import static org.javarosa.core.test.AnswerDataMatchers.stringAnswer;
-import static org.javarosa.core.util.BindBuilderXFormsElement.bind;
-import static org.javarosa.core.util.XFormsElement.body;
-import static org.javarosa.core.util.XFormsElement.head;
-import static org.javarosa.core.util.XFormsElement.html;
-import static org.javarosa.core.util.XFormsElement.input;
-import static org.javarosa.core.util.XFormsElement.mainInstance;
-import static org.javarosa.core.util.XFormsElement.model;
-import static org.javarosa.core.util.XFormsElement.repeat;
-import static org.javarosa.core.util.XFormsElement.t;
-import static org.javarosa.core.util.XFormsElement.title;
+import static org.javarosa.test.BindBuilderXFormsElement.bind;
+import static org.javarosa.test.XFormsElement.body;
+import static org.javarosa.test.XFormsElement.head;
+import static org.javarosa.test.XFormsElement.html;
+import static org.javarosa.test.XFormsElement.input;
+import static org.javarosa.test.XFormsElement.mainInstance;
+import static org.javarosa.test.XFormsElement.model;
+import static org.javarosa.test.XFormsElement.repeat;
+import static org.javarosa.test.XFormsElement.t;
+import static org.javarosa.test.XFormsElement.title;
public class TriggersForRelativeRefsTest {
@Test
diff --git a/src/test/java/org/javarosa/smoketests/ChildVaccinationTest.java b/src/test/java/org/javarosa/smoketests/ChildVaccinationTest.java
index 20d3ffebb..c886eb923 100644
--- a/src/test/java/org/javarosa/smoketests/ChildVaccinationTest.java
+++ b/src/test/java/org/javarosa/smoketests/ChildVaccinationTest.java
@@ -21,7 +21,7 @@
import static org.hamcrest.MatcherAssert.assertThat;
import static org.hamcrest.Matchers.anyOf;
import static org.hamcrest.Matchers.is;
-import static org.javarosa.core.test.Scenario.getRef;
+import static org.javarosa.test.Scenario.getRef;
import static org.javarosa.smoketests.ChildVaccinationTest.Sex.FEMALE;
import static org.javarosa.smoketests.ChildVaccinationTest.Sex.MALE;
import static org.javarosa.smoketests.ChildVaccinationTest.Vaccines.DIPHTERIA;
@@ -37,7 +37,7 @@
import java.util.List;
import java.util.function.Consumer;
import org.javarosa.core.model.instance.TreeReference;
-import org.javarosa.core.test.Scenario;
+import org.javarosa.test.Scenario;
import org.javarosa.xform.parse.XFormParser;
import org.junit.Test;
diff --git a/src/test/java/org/javarosa/smoketests/WhoVATest.java b/src/test/java/org/javarosa/smoketests/WhoVATest.java
index 3fc746001..d47e65485 100644
--- a/src/test/java/org/javarosa/smoketests/WhoVATest.java
+++ b/src/test/java/org/javarosa/smoketests/WhoVATest.java
@@ -21,13 +21,13 @@
import static org.javarosa.core.test.AnswerDataMatchers.intAnswer;
import static org.javarosa.core.test.AnswerDataMatchers.stringAnswer;
import static org.javarosa.core.test.QuestionDefMatchers.nonRelevant;
-import static org.javarosa.core.test.Scenario.getRef;
-import static org.javarosa.test.utils.ResourcePathHelper.r;
+import static org.javarosa.test.Scenario.getRef;
+import static org.javarosa.test.ResourcePathHelper.r;
import static org.junit.Assert.assertThat;
import java.time.LocalDate;
import java.util.stream.IntStream;
-import org.javarosa.core.test.Scenario;
+import org.javarosa.test.Scenario;
import org.javarosa.xform.parse.XFormParser;
import org.junit.Test;
diff --git a/src/test/java/org/javarosa/test/utils/ResourcePathHelper.java b/src/test/java/org/javarosa/test/utils/ResourcePathHelper.java
deleted file mode 100644
index dc56de83b..000000000
--- a/src/test/java/org/javarosa/test/utils/ResourcePathHelper.java
+++ /dev/null
@@ -1,44 +0,0 @@
-package org.javarosa.test.utils;
-
-import static java.nio.file.Files.isRegularFile;
-import static java.nio.file.Files.walk;
-import static java.util.stream.Collectors.toSet;
-
-import java.io.IOException;
-import java.net.URI;
-import java.net.URISyntaxException;
-import java.nio.file.Path;
-import java.nio.file.Paths;
-import java.util.Set;
-
-public class ResourcePathHelper {
- private static Set resourcePathsCache = buildCache();
-
- private static synchronized Set buildCache() {
- try {
- URI uri = ResourcePathHelper.class.getResource("/logback-test.xml.example").toURI();
- Path root = Paths.get(uri).getParent();
- return walk(root)
- .filter(p -> isRegularFile(p))
- .collect(toSet());
- } catch (URISyntaxException | IOException e) {
- throw new RuntimeException(e);
- }
- }
-
- /**
- * Provides the path to the first filename match in a depth-first traversal starting
- * at the test resource root.
- *
- * @param filename the file name for which to create a path
- * @return a Path for the resource file
- */
- public static Path r(String filename) {
- if (resourcePathsCache == null)
- throw new RuntimeException("Too fast! The resources cache hasn't been built yet! Don't use r() within static members!");
- return resourcePathsCache.stream()
- .filter(p -> p.endsWith(filename))
- .findFirst()
- .orElseThrow(() -> new RuntimeException("File " + filename + " not found among files in resources"));
- }
-}
diff --git a/src/test/java/org/javarosa/xform/parse/AttributesTestCase.java b/src/test/java/org/javarosa/xform/parse/AttributesTestCase.java
index d225168f4..a440e4911 100644
--- a/src/test/java/org/javarosa/xform/parse/AttributesTestCase.java
+++ b/src/test/java/org/javarosa/xform/parse/AttributesTestCase.java
@@ -1,12 +1,12 @@
package org.javarosa.xform.parse;
import org.javarosa.core.model.FormDef;
-import org.javarosa.core.test.FormParseInit;
+import org.javarosa.test.FormParseInit;
import org.javarosa.form.api.FormEntryModel;
import org.javarosa.form.api.FormEntryPrompt;
import org.junit.Test;
-import static org.javarosa.test.utils.ResourcePathHelper.r;
+import static org.javarosa.test.ResourcePathHelper.r;
import static org.junit.Assert.assertEquals;
/**
diff --git a/src/test/java/org/javarosa/xform/parse/BindAttributeProcessorTest.java b/src/test/java/org/javarosa/xform/parse/BindAttributeProcessorTest.java
index 5ee6e3cd7..aa55d7bc0 100644
--- a/src/test/java/org/javarosa/xform/parse/BindAttributeProcessorTest.java
+++ b/src/test/java/org/javarosa/xform/parse/BindAttributeProcessorTest.java
@@ -5,7 +5,7 @@
import org.javarosa.core.model.FormDef;
import org.javarosa.core.model.instance.TreeElement;
import org.javarosa.core.model.instance.TreeReference;
-import org.javarosa.core.util.XFormsElement;
+import org.javarosa.test.XFormsElement;
import org.javarosa.model.xform.XPathReference;
import org.junit.Test;
@@ -18,14 +18,14 @@
import static java.util.Arrays.asList;
import static org.hamcrest.MatcherAssert.assertThat;
import static org.hamcrest.Matchers.equalTo;
-import static org.javarosa.core.util.BindBuilderXFormsElement.bind;
-import static org.javarosa.core.util.XFormsElement.body;
-import static org.javarosa.core.util.XFormsElement.head;
-import static org.javarosa.core.util.XFormsElement.input;
-import static org.javarosa.core.util.XFormsElement.mainInstance;
-import static org.javarosa.core.util.XFormsElement.model;
-import static org.javarosa.core.util.XFormsElement.t;
-import static org.javarosa.core.util.XFormsElement.title;
+import static org.javarosa.test.BindBuilderXFormsElement.bind;
+import static org.javarosa.test.XFormsElement.body;
+import static org.javarosa.test.XFormsElement.head;
+import static org.javarosa.test.XFormsElement.input;
+import static org.javarosa.test.XFormsElement.mainInstance;
+import static org.javarosa.test.XFormsElement.model;
+import static org.javarosa.test.XFormsElement.t;
+import static org.javarosa.test.XFormsElement.title;
public class BindAttributeProcessorTest {
diff --git a/src/test/java/org/javarosa/xform/parse/ExternalSecondaryInstanceParseTest.java b/src/test/java/org/javarosa/xform/parse/ExternalSecondaryInstanceParseTest.java
index 949172299..d135c20dd 100644
--- a/src/test/java/org/javarosa/xform/parse/ExternalSecondaryInstanceParseTest.java
+++ b/src/test/java/org/javarosa/xform/parse/ExternalSecondaryInstanceParseTest.java
@@ -6,13 +6,14 @@
import org.javarosa.core.model.data.helper.Selection;
import org.javarosa.core.model.instance.AbstractTreeElement;
import org.javarosa.core.model.instance.TreeReference;
-import org.javarosa.core.test.FormParseInit;
-import org.javarosa.core.test.Scenario;
+import org.javarosa.test.FormParseInit;
+import org.javarosa.test.Scenario;
import org.javarosa.core.util.externalizable.DeserializationException;
import org.javarosa.xpath.expr.XPathPathExpr;
import org.javarosa.xpath.parser.XPathSyntaxException;
import org.junit.Test;
+import java.io.File;
import java.io.FileNotFoundException;
import java.io.IOException;
import java.nio.file.Path;
@@ -22,16 +23,16 @@
import static org.hamcrest.CoreMatchers.nullValue;
import static org.hamcrest.MatcherAssert.assertThat;
import static org.javarosa.core.reference.ReferenceManagerTestUtils.setUpSimpleReferenceManager;
-import static org.javarosa.core.util.BindBuilderXFormsElement.bind;
-import static org.javarosa.core.util.XFormsElement.body;
-import static org.javarosa.core.util.XFormsElement.head;
-import static org.javarosa.core.util.XFormsElement.html;
-import static org.javarosa.core.util.XFormsElement.mainInstance;
-import static org.javarosa.core.util.XFormsElement.model;
-import static org.javarosa.core.util.XFormsElement.select1Dynamic;
-import static org.javarosa.core.util.XFormsElement.t;
-import static org.javarosa.core.util.XFormsElement.title;
-import static org.javarosa.test.utils.ResourcePathHelper.r;
+import static org.javarosa.test.BindBuilderXFormsElement.bind;
+import static org.javarosa.test.XFormsElement.body;
+import static org.javarosa.test.XFormsElement.head;
+import static org.javarosa.test.XFormsElement.html;
+import static org.javarosa.test.XFormsElement.mainInstance;
+import static org.javarosa.test.XFormsElement.model;
+import static org.javarosa.test.XFormsElement.select1Dynamic;
+import static org.javarosa.test.XFormsElement.t;
+import static org.javarosa.test.XFormsElement.title;
+import static org.javarosa.test.ResourcePathHelper.r;
import static org.javarosa.xform.parse.FormParserHelper.deserializeAndCleanUpSerializedForm;
import static org.javarosa.xform.parse.FormParserHelper.getSerializedFormPath;
import static org.javarosa.xform.parse.FormParserHelper.parse;
@@ -173,7 +174,7 @@ public void formWithExternalSecondaryXMLInstance_ShouldSerializeAndDeserialize()
public void deserializedFormDefCreatedFromAFormWithExternalSecondaryXMLInstance_ShouldContainThatExternalInstance() throws IOException, DeserializationException, XFormParser.ParseException {
configureReferenceManagerCorrectly();
- Path formPath = r("external-select-xml.xml");
+ File formPath = r("external-select-xml.xml");
FormDef originalFormDef = parse(r("external-select-xml.xml"));
originalFormDef.setFormXmlPath(formPath.toString());
@@ -298,7 +299,7 @@ public void exceptionFromChoiceSelection_whenFormIsDeserialized_afterPlaceholder
// All external secondary instances and forms are in the same folder. Configure the ReferenceManager to resolve
// URIs to that folder.
public static void configureReferenceManagerCorrectly() {
- setUpSimpleReferenceManager(r("external-select-csv.xml").getParent(), "file-csv", "file");
+ setUpSimpleReferenceManager(r("external-select-csv.xml").getParentFile(), "file-csv", "file");
}
// Configure the ReferenceManager to resolve URIs to a folder that does not exist.
diff --git a/src/test/java/org/javarosa/xform/parse/FormParserHelper.java b/src/test/java/org/javarosa/xform/parse/FormParserHelper.java
index b33beeb1d..2f65baad1 100644
--- a/src/test/java/org/javarosa/xform/parse/FormParserHelper.java
+++ b/src/test/java/org/javarosa/xform/parse/FormParserHelper.java
@@ -10,6 +10,7 @@
import java.io.DataInputStream;
import java.io.DataOutputStream;
+import java.io.File;
import java.io.FileInputStream;
import java.io.IOException;
import java.nio.file.Files;
@@ -22,12 +23,12 @@ public final class FormParserHelper {
private FormParserHelper() {
}
- public static FormDef parse(Path formName) throws IOException, XFormParser.ParseException {
- return XFormUtils.getFormFromInputStream(new FileInputStream(formName.toString()));
+ public static FormDef parse(File formName) throws IOException, XFormParser.ParseException {
+ return XFormUtils.getFormFromInputStream(new FileInputStream(formName));
}
- public static FormDef parse(Path formName, String lastSavedSrc) throws IOException, XFormParser.ParseException {
- return XFormUtils.getFormFromInputStream(new FileInputStream(formName.toString()), lastSavedSrc);
+ public static FormDef parse(File formName, String lastSavedSrc) throws IOException, XFormParser.ParseException {
+ return XFormUtils.getFormFromInputStream(new FileInputStream(formName), lastSavedSrc);
}
static Path getSerializedFormPath(FormDef formDef) throws IOException {
diff --git a/src/test/java/org/javarosa/xform/parse/XFormParserTest.java b/src/test/java/org/javarosa/xform/parse/XFormParserTest.java
index b637c46d6..687b34d0f 100644
--- a/src/test/java/org/javarosa/xform/parse/XFormParserTest.java
+++ b/src/test/java/org/javarosa/xform/parse/XFormParserTest.java
@@ -9,15 +9,15 @@
import static org.javarosa.core.model.Constants.CONTROL_RANGE;
import static org.javarosa.core.model.Constants.CONTROL_RANK;
import static org.javarosa.core.test.AnswerDataMatchers.intAnswer;
-import static org.javarosa.core.util.BindBuilderXFormsElement.bind;
-import static org.javarosa.core.util.XFormsElement.body;
-import static org.javarosa.core.util.XFormsElement.head;
-import static org.javarosa.core.util.XFormsElement.html;
-import static org.javarosa.core.util.XFormsElement.input;
-import static org.javarosa.core.util.XFormsElement.mainInstance;
-import static org.javarosa.core.util.XFormsElement.model;
-import static org.javarosa.core.util.XFormsElement.t;
-import static org.javarosa.test.utils.ResourcePathHelper.r;
+import static org.javarosa.test.BindBuilderXFormsElement.bind;
+import static org.javarosa.test.XFormsElement.body;
+import static org.javarosa.test.XFormsElement.head;
+import static org.javarosa.test.XFormsElement.html;
+import static org.javarosa.test.XFormsElement.input;
+import static org.javarosa.test.XFormsElement.mainInstance;
+import static org.javarosa.test.XFormsElement.model;
+import static org.javarosa.test.XFormsElement.t;
+import static org.javarosa.test.ResourcePathHelper.r;
import static org.javarosa.xform.parse.FormParserHelper.deserializeAndCleanUpSerializedForm;
import static org.javarosa.xform.parse.FormParserHelper.getSerializedFormPath;
import static org.javarosa.xform.parse.FormParserHelper.parse;
@@ -25,6 +25,7 @@
import static org.junit.Assert.assertNotNull;
import static org.junit.Assert.assertNull;
+import java.io.File;
import java.io.IOException;
import java.io.UncheckedIOException;
import java.nio.file.Files;
@@ -47,7 +48,7 @@
import org.javarosa.core.model.instance.TreeReference;
import org.javarosa.core.reference.ReferenceManagerTestUtils;
import org.javarosa.core.services.transport.payload.ByteArrayPayload;
-import org.javarosa.core.test.Scenario;
+import org.javarosa.test.Scenario;
import org.javarosa.core.util.externalizable.DeserializationException;
import org.javarosa.model.xform.XFormSerializingVisitor;
import org.javarosa.model.xform.XPathReference;
@@ -65,7 +66,7 @@ public class XFormParserTest {
private static final Logger logger = LoggerFactory.getLogger(XFormParserTest.class);
private static Path FORM_INSTANCE_XML_FILE_NAME;
- private static Path SECONDARY_INSTANCE_XML;
+ private static File SECONDARY_INSTANCE_XML;
private static Path SECONDARY_INSTANCE_LARGE_XML;
private static final String AUDIT_NODE = "audit";
@@ -143,14 +144,14 @@ public void parsesSecondaryInstanceForm() throws IOException, XFormParser.ParseE
@Test
public void parsesSecondaryInstanceForm2() throws IOException, XFormParser.ParseException {
- Path formName = r("internal_select_10.xml");
+ File formName = r("internal_select_10.xml");
FormDef formDef = parse(formName);
assertEquals("internal select 10", formDef.getTitle());
}
@Test
public void parsesLastSavedInstanceWithNullSrc() throws IOException, XFormParser.ParseException {
- Path formName = r("last-saved-blank.xml");
+ File formName = r("last-saved-blank.xml");
FormDef formDef = parse(formName, null);
assertEquals("Form with last-saved instance (blank)", formDef.getTitle());
@@ -161,8 +162,8 @@ public void parsesLastSavedInstanceWithNullSrc() throws IOException, XFormParser
@Test
public void parsesLastSavedInstanceWithFilledForm() throws IOException, XFormParser.ParseException {
- Path formName = r("last-saved-blank.xml");
- Path lastSavedSubmissionDirectory = r("last-saved-filled.xml").toAbsolutePath().getParent();
+ File formName = r("last-saved-blank.xml");
+ File lastSavedSubmissionDirectory = r("last-saved-filled.xml").getParentFile();
ReferenceManagerTestUtils.setUpSimpleReferenceManager(lastSavedSubmissionDirectory, "file");
FormDef formDef = parse(formName, "jr://file/last-saved-filled.xml");
assertEquals("Form with last-saved instance (blank)", formDef.getTitle());
@@ -233,7 +234,7 @@ public void throwsExceptionOnEmptySelect() throws IOException, XFormParser.Parse
exceptionRule.expect(XFormParseException.class);
exceptionRule.expectMessage("Select question 'First' has no choices");
- Path formName = r("internal_empty_select.xml");
+ File formName = r("internal_empty_select.xml");
FormDef formDef = parse(formName);
}
diff --git a/src/test/java/org/javarosa/xform/parse/XPathProcessorTest.java b/src/test/java/org/javarosa/xform/parse/XPathProcessorTest.java
index 301dbea90..84268f784 100644
--- a/src/test/java/org/javarosa/xform/parse/XPathProcessorTest.java
+++ b/src/test/java/org/javarosa/xform/parse/XPathProcessorTest.java
@@ -1,6 +1,6 @@
package org.javarosa.xform.parse;
-import org.javarosa.core.util.XFormsElement;
+import org.javarosa.test.XFormsElement;
import org.javarosa.xpath.expr.XPathExpression;
import org.javarosa.xpath.expr.XPathPathExpr;
import org.javarosa.xpath.expr.XPathQName;
@@ -16,13 +16,13 @@
import static org.hamcrest.MatcherAssert.assertThat;
import static org.hamcrest.Matchers.contains;
import static org.hamcrest.Matchers.equalTo;
-import static org.javarosa.core.util.BindBuilderXFormsElement.bind;
-import static org.javarosa.core.util.XFormsElement.body;
-import static org.javarosa.core.util.XFormsElement.head;
-import static org.javarosa.core.util.XFormsElement.input;
-import static org.javarosa.core.util.XFormsElement.mainInstance;
-import static org.javarosa.core.util.XFormsElement.model;
-import static org.javarosa.core.util.XFormsElement.t;
+import static org.javarosa.test.BindBuilderXFormsElement.bind;
+import static org.javarosa.test.XFormsElement.body;
+import static org.javarosa.test.XFormsElement.head;
+import static org.javarosa.test.XFormsElement.input;
+import static org.javarosa.test.XFormsElement.mainInstance;
+import static org.javarosa.test.XFormsElement.model;
+import static org.javarosa.test.XFormsElement.t;
public class XPathProcessorTest {
diff --git a/src/test/java/org/javarosa/xml/TreeElementParserTest.java b/src/test/java/org/javarosa/xml/TreeElementParserTest.java
index 04a3e8983..3bc0e2c2f 100644
--- a/src/test/java/org/javarosa/xml/TreeElementParserTest.java
+++ b/src/test/java/org/javarosa/xml/TreeElementParserTest.java
@@ -7,21 +7,21 @@
import org.kxml2.io.KXmlParser;
import org.xmlpull.v1.XmlPullParserException;
+import java.io.File;
import java.io.FileInputStream;
import java.io.IOException;
import java.io.InputStream;
-import java.nio.file.Path;
import java.util.List;
import static org.hamcrest.Matchers.empty;
import static org.hamcrest.Matchers.is;
-import static org.javarosa.test.utils.ResourcePathHelper.r;
+import static org.javarosa.test.ResourcePathHelper.r;
import static org.junit.Assert.assertEquals;
import static org.junit.Assert.assertThat;
public class TreeElementParserTest {
- private static Path SECONDARY_INSTANCE_XML;
+ private static File SECONDARY_INSTANCE_XML;
@Before
public void setUp() {
diff --git a/src/test/java/org/javarosa/xpath/XPathConditionalTriggersTest.java b/src/test/java/org/javarosa/xpath/XPathConditionalTriggersTest.java
index 7961a64d7..794e346ab 100644
--- a/src/test/java/org/javarosa/xpath/XPathConditionalTriggersTest.java
+++ b/src/test/java/org/javarosa/xpath/XPathConditionalTriggersTest.java
@@ -1,7 +1,7 @@
package org.javarosa.xpath;
import org.javarosa.core.model.instance.TreeReference;
-import org.javarosa.core.test.Scenario;
+import org.javarosa.test.Scenario;
import org.javarosa.xpath.parser.XPathSyntaxException;
import org.junit.Test;
diff --git a/src/test/java/org/javarosa/xpath/expr/Base64DecodeTest.java b/src/test/java/org/javarosa/xpath/expr/Base64DecodeTest.java
index fc4f5c6e1..5641e4cde 100644
--- a/src/test/java/org/javarosa/xpath/expr/Base64DecodeTest.java
+++ b/src/test/java/org/javarosa/xpath/expr/Base64DecodeTest.java
@@ -5,19 +5,19 @@
import static org.hamcrest.Matchers.is;
import static org.hamcrest.Matchers.nullValue;
import static org.javarosa.core.test.AnswerDataMatchers.stringAnswer;
-import static org.javarosa.core.util.BindBuilderXFormsElement.bind;
-import static org.javarosa.core.util.XFormsElement.body;
-import static org.javarosa.core.util.XFormsElement.head;
-import static org.javarosa.core.util.XFormsElement.html;
-import static org.javarosa.core.util.XFormsElement.input;
-import static org.javarosa.core.util.XFormsElement.mainInstance;
-import static org.javarosa.core.util.XFormsElement.model;
-import static org.javarosa.core.util.XFormsElement.t;
-import static org.javarosa.core.util.XFormsElement.title;
+import static org.javarosa.test.BindBuilderXFormsElement.bind;
+import static org.javarosa.test.XFormsElement.body;
+import static org.javarosa.test.XFormsElement.head;
+import static org.javarosa.test.XFormsElement.html;
+import static org.javarosa.test.XFormsElement.input;
+import static org.javarosa.test.XFormsElement.mainInstance;
+import static org.javarosa.test.XFormsElement.model;
+import static org.javarosa.test.XFormsElement.t;
+import static org.javarosa.test.XFormsElement.title;
import static org.junit.Assert.fail;
import java.io.IOException;
-import org.javarosa.core.test.Scenario;
+import org.javarosa.test.Scenario;
import org.javarosa.xform.parse.XFormParser;
import org.javarosa.xpath.XPathUnhandledException;
import org.junit.Test;
diff --git a/src/test/java/org/javarosa/xpath/expr/CurrentFieldRefTest.java b/src/test/java/org/javarosa/xpath/expr/CurrentFieldRefTest.java
index de65c9c06..fafd1d9a3 100644
--- a/src/test/java/org/javarosa/xpath/expr/CurrentFieldRefTest.java
+++ b/src/test/java/org/javarosa/xpath/expr/CurrentFieldRefTest.java
@@ -19,7 +19,7 @@
import static org.hamcrest.Matchers.is;
import static org.javarosa.core.test.AnswerDataMatchers.stringAnswer;
-import org.javarosa.core.test.Scenario;
+import org.javarosa.test.Scenario;
import org.javarosa.xform.parse.XFormParser;
import org.junit.Before;
import org.junit.Test;
diff --git a/src/test/java/org/javarosa/xpath/expr/CurrentGroupCountRefTest.java b/src/test/java/org/javarosa/xpath/expr/CurrentGroupCountRefTest.java
index 5aac2d79b..15a5cf5e4 100644
--- a/src/test/java/org/javarosa/xpath/expr/CurrentGroupCountRefTest.java
+++ b/src/test/java/org/javarosa/xpath/expr/CurrentGroupCountRefTest.java
@@ -19,7 +19,7 @@
import static org.hamcrest.Matchers.is;
import static org.javarosa.core.test.AnswerDataMatchers.stringAnswer;
-import org.javarosa.core.test.Scenario;
+import org.javarosa.test.Scenario;
import org.javarosa.xform.parse.XFormParser;
import org.junit.Before;
import org.junit.Test;
diff --git a/src/test/java/org/javarosa/xpath/expr/CurrentTest.java b/src/test/java/org/javarosa/xpath/expr/CurrentTest.java
index 9597c60c2..58f22c441 100644
--- a/src/test/java/org/javarosa/xpath/expr/CurrentTest.java
+++ b/src/test/java/org/javarosa/xpath/expr/CurrentTest.java
@@ -23,7 +23,7 @@
import java.util.List;
import org.javarosa.core.model.SelectChoice;
-import org.javarosa.core.test.Scenario;
+import org.javarosa.test.Scenario;
import org.javarosa.xform.parse.XFormParser;
import org.junit.Before;
import org.junit.Test;
diff --git a/src/test/java/org/javarosa/xpath/expr/DigestTest.java b/src/test/java/org/javarosa/xpath/expr/DigestTest.java
index 556aed119..91280b7f2 100644
--- a/src/test/java/org/javarosa/xpath/expr/DigestTest.java
+++ b/src/test/java/org/javarosa/xpath/expr/DigestTest.java
@@ -17,15 +17,15 @@
import static org.hamcrest.Matchers.is;
import static org.javarosa.core.test.AnswerDataMatchers.stringAnswer;
-import static org.javarosa.core.util.BindBuilderXFormsElement.bind;
-import static org.javarosa.core.util.XFormsElement.body;
-import static org.javarosa.core.util.XFormsElement.head;
-import static org.javarosa.core.util.XFormsElement.html;
-import static org.javarosa.core.util.XFormsElement.input;
-import static org.javarosa.core.util.XFormsElement.mainInstance;
-import static org.javarosa.core.util.XFormsElement.model;
-import static org.javarosa.core.util.XFormsElement.t;
-import static org.javarosa.core.util.XFormsElement.title;
+import static org.javarosa.test.BindBuilderXFormsElement.bind;
+import static org.javarosa.test.XFormsElement.body;
+import static org.javarosa.test.XFormsElement.head;
+import static org.javarosa.test.XFormsElement.html;
+import static org.javarosa.test.XFormsElement.input;
+import static org.javarosa.test.XFormsElement.mainInstance;
+import static org.javarosa.test.XFormsElement.model;
+import static org.javarosa.test.XFormsElement.t;
+import static org.javarosa.test.XFormsElement.title;
import static org.javarosa.xpath.expr.DigestAlgorithm.MD5;
import static org.javarosa.xpath.expr.DigestAlgorithm.SHA1;
import static org.javarosa.xpath.expr.DigestAlgorithm.SHA256;
@@ -38,7 +38,7 @@
import java.io.IOException;
import java.util.Arrays;
-import org.javarosa.core.test.Scenario;
+import org.javarosa.test.Scenario;
import org.javarosa.xform.parse.XFormParser;
import org.junit.Test;
import org.junit.runner.RunWith;
diff --git a/src/test/java/org/javarosa/xpath/expr/ExtractSignedTest.java b/src/test/java/org/javarosa/xpath/expr/ExtractSignedTest.java
index cf9ba3439..7b1285f11 100644
--- a/src/test/java/org/javarosa/xpath/expr/ExtractSignedTest.java
+++ b/src/test/java/org/javarosa/xpath/expr/ExtractSignedTest.java
@@ -8,7 +8,7 @@
import org.bouncycastle.crypto.params.Ed25519KeyGenerationParameters;
import org.bouncycastle.crypto.params.Ed25519PublicKeyParameters;
import org.bouncycastle.crypto.signers.Ed25519Signer;
-import org.javarosa.core.test.Scenario;
+import org.javarosa.test.Scenario;
import org.javarosa.xform.parse.XFormParser;
import org.javarosa.xpath.XPathUnhandledException;
import org.jetbrains.annotations.NotNull;
@@ -24,15 +24,15 @@
import static org.hamcrest.Matchers.is;
import static org.hamcrest.Matchers.nullValue;
import static org.javarosa.core.test.AnswerDataMatchers.stringAnswer;
-import static org.javarosa.core.util.BindBuilderXFormsElement.bind;
-import static org.javarosa.core.util.XFormsElement.body;
-import static org.javarosa.core.util.XFormsElement.head;
-import static org.javarosa.core.util.XFormsElement.html;
-import static org.javarosa.core.util.XFormsElement.input;
-import static org.javarosa.core.util.XFormsElement.mainInstance;
-import static org.javarosa.core.util.XFormsElement.model;
-import static org.javarosa.core.util.XFormsElement.t;
-import static org.javarosa.core.util.XFormsElement.title;
+import static org.javarosa.test.BindBuilderXFormsElement.bind;
+import static org.javarosa.test.XFormsElement.body;
+import static org.javarosa.test.XFormsElement.head;
+import static org.javarosa.test.XFormsElement.html;
+import static org.javarosa.test.XFormsElement.input;
+import static org.javarosa.test.XFormsElement.mainInstance;
+import static org.javarosa.test.XFormsElement.model;
+import static org.javarosa.test.XFormsElement.t;
+import static org.javarosa.test.XFormsElement.title;
import static org.junit.Assert.fail;
public class ExtractSignedTest {
diff --git a/src/test/java/org/javarosa/xpath/expr/RandomizeTest.java b/src/test/java/org/javarosa/xpath/expr/RandomizeTest.java
index b405e7745..7f1c56a4b 100644
--- a/src/test/java/org/javarosa/xpath/expr/RandomizeTest.java
+++ b/src/test/java/org/javarosa/xpath/expr/RandomizeTest.java
@@ -22,7 +22,7 @@
import static org.javarosa.core.model.instance.TreeReference.CONTEXT_ABSOLUTE;
import static org.javarosa.core.model.instance.TreeReference.INDEX_UNBOUND;
import static org.javarosa.core.model.instance.TreeReference.REF_ABSOLUTE;
-import static org.javarosa.test.utils.ResourcePathHelper.r;
+import static org.javarosa.test.ResourcePathHelper.r;
import static org.junit.Assert.assertEquals;
import static org.junit.Assert.assertFalse;
import static org.junit.Assert.assertTrue;
@@ -40,7 +40,7 @@
import org.javarosa.core.model.instance.InstanceInitializationFactory;
import org.javarosa.core.model.instance.TreeReference;
import org.javarosa.core.services.PrototypeManager;
-import org.javarosa.core.test.FormParseInit;
+import org.javarosa.test.FormParseInit;
import org.javarosa.core.util.JavaRosaCoreModule;
import org.javarosa.core.util.externalizable.DeserializationException;
import org.javarosa.form.api.FormEntryPrompt;
diff --git a/src/test/resources/logback-test.xml.example b/src/test/resources/logback-test.xml.example
index 6036322b0..ccc86bbaa 100644
--- a/src/test/resources/logback-test.xml.example
+++ b/src/test/resources/logback-test.xml.example
@@ -11,7 +11,7 @@
-
+