Skip to content

Commit

Permalink
Fix constant tests
Browse files Browse the repository at this point in the history
  • Loading branch information
matejdro committed Mar 15, 2023
1 parent cfedfb0 commit 9eabd66
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions tests/test_constants.py
Expand Up @@ -86,7 +86,7 @@ def test_constants(self):
# CMD_CURRENT_APP11
self.assertCommand(
constants.CMD_CURRENT_APP11,
r"CURRENT_APP=$(dumpsys window windows | grep 'mInputMethodTarget') && CURRENT_APP=${CURRENT_APP%%/*} && CURRENT_APP=${CURRENT_APP##* } && echo $CURRENT_APP",
r"CURRENT_APP=$(dumpsys window windows | grep -E -m 1 'mInputMethod(Input)?Target') && CURRENT_APP=${CURRENT_APP%%/*} && CURRENT_APP=${CURRENT_APP##* } && echo $CURRENT_APP",
)

# CMD_CURRENT_APP_GOOGLE_TV
Expand All @@ -104,7 +104,7 @@ def test_constants(self):
# CMD_CURRENT_APP_MEDIA_SESSION_STATE11
self.assertCommand(
constants.CMD_CURRENT_APP_MEDIA_SESSION_STATE11,
r"CURRENT_APP=$(dumpsys window windows | grep 'mInputMethodTarget') && CURRENT_APP=${CURRENT_APP%%/*} && CURRENT_APP=${CURRENT_APP##* } && echo $CURRENT_APP && dumpsys media_session | grep -A 100 'Sessions Stack' | grep -A 100 $CURRENT_APP | grep -m 1 'state=PlaybackState {'",
r"CURRENT_APP=$(dumpsys window windows | grep -E -m 1 'mInputMethod(Input)?Target') && CURRENT_APP=${CURRENT_APP%%/*} && CURRENT_APP=${CURRENT_APP##* } && echo $CURRENT_APP && dumpsys media_session | grep -A 100 'Sessions Stack' | grep -A 100 $CURRENT_APP | grep -m 1 'state=PlaybackState {'",
)

# CMD_CURRENT_APP_MEDIA_SESSION_STATE_GOOGLE_TV
Expand Down Expand Up @@ -143,7 +143,7 @@ def test_constants(self):
# CMD_LAUNCH_APP11
self.assertCommand(
constants.CMD_LAUNCH_APP11,
r"CURRENT_APP=$(dumpsys window windows | grep 'mInputMethodTarget') && CURRENT_APP=${{CURRENT_APP%%/*}} && CURRENT_APP=${{CURRENT_APP##* }} && if [ $CURRENT_APP != '{0}' ]; then monkey -p {0} -c android.intent.category.LEANBACK_LAUNCHER --pct-syskeys 0 1; fi",
r"CURRENT_APP=$(dumpsys window windows | grep -E -m 1 'mInputMethod(Input)?Target') && CURRENT_APP=${{CURRENT_APP%%/*}} && CURRENT_APP=${{CURRENT_APP##* }} && if [ $CURRENT_APP != '{0}' ]; then monkey -p {0} -c android.intent.category.LEANBACK_LAUNCHER --pct-syskeys 0 1; fi",
)

# CMD_LAUNCH_APP_FIRETV
Expand Down

0 comments on commit 9eabd66

Please sign in to comment.