Skip to content

backport ephemeral test users from v3 into v2

luna requested to merge ephemeral-test-users into master

instead of hardcoding hi, admin, etc as users, we dynamically create ephemeral test users throughout the test session that are then deleted once the session finishes.

the implementation details is that we have more fixtures declared in conftest.py that create/teardown those test users, and instead of calling login_normal or login_admin, the fixtures are used instead.

some optimizations include:

  • removing unecessary tests
  • keeping the stored user data for longer, instead of refreshing all the time
    • login_normal always involves an /api/login call

in my dev machine, the test suite run time decreased from 60 seconds to 20 seconds.

Edited by luna

Merge request reports