1811 fix test error
Description
FileObserver was catching file event during QA's test set up and thus generate failure (also due to how test is made)
this MR add another adb compatible debug command to enable/disable FileObserver
This will be used in QA's test to disable FO during test environement set up
logs
vincent@Multivac:~/Sources/TESTS/e2e-os$ adb connect 192.168.1.12:5555
connected to 192.168.1.12:5555
vincent@Multivac:~/Sources/TESTS/e2e-os$ ANDROID_SERIAL=$(adb get-serialno) pytest tests/test_files_sync.py
================================== test session starts ===================================
platform linux -- Python 3.10.12, pytest-7.2.2, pluggy-1.3.0
rootdir: /home/vincent/Sources/TESTS/e2e-os, configfile: pytest.ini
plugins: docker-1.0.1, anyio-4.1.0
collected 2 items
tests/test_files_sync.py .. [100%]
============================== 2 passed in 63.20s (0:01:03) ==============================
vincent@Multivac:~/Sources/TESTS/e2e-os$ adb connect 192.168.1.12:5555
connected to 192.168.1.12:5555
vincent@Multivac:~/Sources/TESTS/e2e-os$ ANDROID_SERIAL=$(adb get-serialno) pytest tests/test_files_sync.py
================================== test session starts ===================================
platform linux -- Python 3.10.12, pytest-7.2.2, pluggy-1.3.0
rootdir: /home/vincent/Sources/TESTS/e2e-os, configfile: pytest.ini
plugins: docker-1.0.1, anyio-4.1.0
collected 2 items
tests/test_files_sync.py .. [100%]
============================== 2 passed in 63.69s (0:01:03) ==============================
vincent@Multivac:~/Sources/TESTS/e2e-os$ adb connect 192.168.1.12:5555
connected to 192.168.1.12:5555
vincent@Multivac:~/Sources/TESTS/e2e-os$ ANDROID_SERIAL=$(adb get-serialno) pytest tests/test_files_sync.py
================================== test session starts ===================================
platform linux -- Python 3.10.12, pytest-7.2.2, pluggy-1.3.0
rootdir: /home/vincent/Sources/TESTS/e2e-os, configfile: pytest.ini
plugins: docker-1.0.1, anyio-4.1.0
collected 2 items
tests/test_files_sync.py .. [100%]
============================== 2 passed in 64.90s (0:01:04) ==============================
vincent@Multivac:~/Sources/TESTS/e2e-os$ git status
Technical details
Also depends of QA's test script update on this MR: https://gitlab.e.foundation/e/qa/e2e-os/-/merge_requests/37
the new command to use is:
adb shell am broadcast -a foundation.e.drive.action.ENABLE_FILE_OBSERVER --receiver-include-background --ez file_observer_enable <true/false>
Tests
-
Run QA's test script 3 times in a row
Issues
https://gitlab.e.foundation/e/os/backlog/-/issues/1811