diff options
| author | Bananeweizen <bananeweizen@gmx.de> | 2013-09-15 18:07:20 +0200 |
|---|---|---|
| committer | Bananeweizen <bananeweizen@gmx.de> | 2013-09-15 18:07:42 +0200 |
| commit | 693b9f4bdeb275c7aa9e12f3f24ebee9aad53be6 (patch) | |
| tree | 3acdca769ccd59db1f49bc52a7fa1c038c4f79f9 /tests/res | |
| parent | ec5c569f35730fa608a1ea83d46e4e60f1985310 (diff) | |
| download | cgeo-693b9f4bdeb275c7aa9e12f3f24ebee9aad53be6.zip cgeo-693b9f4bdeb275c7aa9e12f3f24ebee9aad53be6.tar.gz cgeo-693b9f4bdeb275c7aa9e12f3f24ebee9aad53be6.tar.bz2 | |
refactoring: tests can now be run as app
* run unit tests app as normal android app (it has a launcher now)
* hit "run tests" button
* enjoy the log flying by
Diffstat (limited to 'tests/res')
| -rw-r--r-- | tests/res/layout/cgeo_tests_activity.xml | 54 | ||||
| -rw-r--r-- | tests/res/values/strings.xml | 2 |
2 files changed, 56 insertions, 0 deletions
diff --git a/tests/res/layout/cgeo_tests_activity.xml b/tests/res/layout/cgeo_tests_activity.xml new file mode 100644 index 0000000..ba87829 --- /dev/null +++ b/tests/res/layout/cgeo_tests_activity.xml @@ -0,0 +1,54 @@ +<?xml version="1.0" encoding="utf-8"?> +<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android" + xmlns:tools="http://schemas.android.com/tools" + android:id="@+id/RelativeLayout1" + android:layout_width="match_parent" + android:layout_height="match_parent" + android:layout_marginLeft="6dp" + android:layout_marginRight="6dp" + android:orientation="vertical" > + + <TextView + android:id="@+id/headline" + android:layout_width="match_parent" + android:layout_height="wrap_content" + android:layout_alignParentLeft="true" + android:layout_alignParentTop="true" + android:layout_gravity="center_vertical" + android:gravity="center_vertical" + android:lines="1" + android:singleLine="true" + android:text="@string/logcat" + android:textAppearance="?android:attr/textAppearanceLarge" /> + + <ScrollView + android:id="@+id/scrollView" + android:layout_width="match_parent" + android:layout_height="fill_parent" + android:layout_above="@+id/buttonRun" + android:layout_alignParentLeft="true" + android:layout_below="@+id/headline" > + + <TextView + android:id="@+id/logOutput" + android:layout_width="fill_parent" + android:layout_height="wrap_content" + android:textSize="8sp" + tools:ignore="SmallSp" /> + </ScrollView> + + <Button + android:id="@+id/buttonRun" + android:layout_width="match_parent" + android:layout_height="wrap_content" + android:layout_alignParentBottom="true" + android:layout_alignParentLeft="false" + android:onClick="runTests" + android:text="@string/run_tests" /> + + <requestFocus + android:layout_alignTop="@+id/buttonRun" + android:layout_centerHorizontal="true" + android:layout_marginTop="18dp" /> + +</RelativeLayout>
\ No newline at end of file diff --git a/tests/res/values/strings.xml b/tests/res/values/strings.xml index 6f4b38a..1230358 100644 --- a/tests/res/values/strings.xml +++ b/tests/res/values/strings.xml @@ -2,5 +2,7 @@ <resources> <string name="app_name">c:geo tests</string> + <string name="logcat">Logcat:</string> + <string name="run_tests">Run tests…</string> </resources>
\ No newline at end of file |
