Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Minimal cross platform UI testing #1772

Closed
5 tasks
4xiom5 opened this issue Mar 7, 2024 · 0 comments · Fixed by #1791
Closed
5 tasks

Minimal cross platform UI testing #1772

4xiom5 opened this issue Mar 7, 2024 · 0 comments · Fixed by #1791
Assignees
Labels
ci/cd continuous integration / continuous delivery fe1-web fe2-android

Comments

@4xiom5
Copy link
Contributor

4xiom5 commented Mar 7, 2024

Current Status

Currently, cross-platform UI tests are conducted using Karate and Appium (tests/karate/src/test/java/fe). These tests depend on a mock backend to partially simulate a server. In certain tests, messages exchanged with the server are inspected to ascertain the correct functioning of the client. While this approach allows for protocol adherence verification, it often results in convoluted and hard-to-read tests.

Proposed Approach

First, using a real implementation of the backend instead of a mock server. This should be sufficient for most test cases and simplify greatly the test writing process. Then, establishing a minimal UI specification that all frontends must adhere to. Frontends would be tested as black boxes, using only simulated user inputs and visual feedback. Finally, executed those tests across various devices and platforms, capturing screenshots to facilitate rapid identification of UI bugs. Karate and Appium should provide the necessary feature for the implementation.

Comparison

Pros

  • Tests become more intuitive.
  • Reduced effort in maintaining a mock backend server.
  • Allows testing for (retro)compatibility between frontends and backends.

Cons

  • Inability to directly verify client adherence to the protocol.
  • Some bugs may stem from server-side issues.
  • Unability to test for frontend response to malicious backends.

Proposed Plan

  • Test feasability by creating one simple test and the necessary tools for executing it across multiple browsers/emulators on the backend(s) of choice.
  • Define minimal UI requirements.
  • Implement tests for these minimal UI requirements.
  • (Optional) Integrate some tests into the CI pipeline.
  • (Optional) Construct a websocket proxy to test more complex scenarios (e.g. malicious backends, multi-server communication, ...).
@4xiom5 4xiom5 added fe1-web fe2-android ci/cd continuous integration / continuous delivery labels Mar 7, 2024
@4xiom5 4xiom5 self-assigned this Mar 7, 2024
@4xiom5 4xiom5 linked a pull request Mar 25, 2024 that will close this issue
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
ci/cd continuous integration / continuous delivery fe1-web fe2-android
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant