Tests for double tapping camera
claudds opened this issue · comments
Add in tests for double tapping the camera
- unit test?
- acceptance test
- Espresso test
ideal hours:
Related story: #95
Acceptance tests written and tested on emulator and android phone.
Time Taken: 1 hour
Espresso test completed. UI elements checked for direction of camera before and after double tapping the general camera area.
Time taken: 3 hours
Unit tests completed for camera double tap feature. Tests include:
CameraViewUnitTest
Tests the existing flipCamera() method, asserting the toggling of the cameraId based on whether the camera faces back or front.
DoubleTapGestureDetectorUnitTest
Tests that a double tap event is captured; assert that onDoubleTapEvent() is true and onSingleTapConfirmed() is false in this case, and verifies that the flipCamera() method is invoked by the CameraView when the double tap event is triggered. Also tests the icon visibility when camera is flipped.
Time taken: 3.5 hours