diff options
author | Phil Burk <philburk@mobileer.com> | 2022-08-31 15:20:09 -0700 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-08-31 15:20:09 -0700 |
commit | 28fe61a8c0e911c08a8dc91751164895527e812c (patch) | |
tree | 962fea7ec87f59fb2054e9bdc185956f07f4a514 /apps/OboeTester/app/src/main/res | |
parent | 095df3c19177c02b67f33e92876d5646cf48ce16 (diff) | |
download | oboe-28fe61a8c0e911c08a8dc91751164895527e812c.tar.gz |
OboeTester: add error callback test (#1614)
Delete an error callback while it is being used by Oboe.
Try to reproduce issue #1603
Diffstat (limited to 'apps/OboeTester/app/src/main/res')
3 files changed, 50 insertions, 1 deletions
diff --git a/apps/OboeTester/app/src/main/res/layout/activity_error_callback.xml b/apps/OboeTester/app/src/main/res/layout/activity_error_callback.xml new file mode 100644 index 00000000..3abc11e9 --- /dev/null +++ b/apps/OboeTester/app/src/main/res/layout/activity_error_callback.xml @@ -0,0 +1,35 @@ +<?xml version="1.0" encoding="utf-8"?> +<android.support.constraint.ConstraintLayout xmlns:android="http://schemas.android.com/apk/res/android" + xmlns:app="http://schemas.android.com/apk/res-auto" + xmlns:tools="http://schemas.android.com/tools" + android:layout_width="match_parent" + android:layout_height="match_parent" + tools:context=".TestErrorCallbackActivity"> + + <GridLayout + android:id="@+id/buttonGrid" + android:layout_width="match_parent" + android:layout_height="wrap_content" + android:columnCount="1"> + + <Button + android:id="@+id/buttonTestDeleteCrash" + android:layout_width="0dp" + android:layout_height="wrap_content" + android:layout_columnWeight="1" + android:layout_gravity="fill" + android:backgroundTint="@color/button_tint" + android:onClick="onTestDeleteCrash" + android:text="Delete Callback" /> + + <TextView + android:id="@+id/text_callback_status" + android:layout_width="match_parent" + android:layout_height="match_parent" + android:fontFamily="monospace" + android:gravity="bottom" + android:text="@string/init_status" + /> + +</GridLayout> +</android.support.constraint.ConstraintLayout> diff --git a/apps/OboeTester/app/src/main/res/layout/activity_extra_tests.xml b/apps/OboeTester/app/src/main/res/layout/activity_extra_tests.xml index 14aa80f9..dbd0d37e 100644 --- a/apps/OboeTester/app/src/main/res/layout/activity_extra_tests.xml +++ b/apps/OboeTester/app/src/main/res/layout/activity_extra_tests.xml @@ -41,5 +41,15 @@ android:backgroundTint="@color/button_tint" android:onClick="onLaunchPlugLatencyTest" android:text="Plug Latency" /> - </GridLayout> + + <Button + android:id="@+id/buttonErrorCallback" + android:layout_gravity="fill" + android:layout_width="0dp" + android:layout_columnWeight="1" + android:layout_height="wrap_content" + android:backgroundTint="@color/button_tint" + android:onClick="onLaunchErrorCallbackTest" + android:text="Error Callback" /> +</GridLayout> </android.support.constraint.ConstraintLayout> diff --git a/apps/OboeTester/app/src/main/res/values/strings.xml b/apps/OboeTester/app/src/main/res/values/strings.xml index ae03a606..bf1a6768 100644 --- a/apps/OboeTester/app/src/main/res/values/strings.xml +++ b/apps/OboeTester/app/src/main/res/values/strings.xml @@ -190,6 +190,9 @@ <string name="duration">Duration:</string> <string name="auto_default_status">Status...</string> <string name="device_report">Device Report</string> + <string name="plug_or_unplug">Plug in or Unplug a Headset</string> + <string name="report_magic_pass">PASS, got %X"</string> + <string name="report_magic_fail">FAIL, got %X, expected %X"</string> <string name="log_of_test_results">Log of Test Results</string> <string name="save_file">Save</string> @@ -201,6 +204,7 @@ <string name="test_disconnect_instructions">Disconnect all headsets.\nPress [START]</string> <string name="title_external_tap">External Tap To Tone</string> <string name="title_plug_latency">Plug Latency Test</string> + <string name="title_error_callback">Error Callback Test</string> <string name="analyze">Analyze</string> <string-array name="conversion_qualities"> |