There are several points we could optimize in a long term all the functional tests:
Suites:
We have already some suites defined in nuxeo-brand-management-ftest/src/config/wdio.conf.js. We could set them in the QA configuration for having different jobs running the appropriate suites.
Tags:
We could use @small, @medium and @large, or maybe @hare, @tortoise, and @sloth and having different QA Ftests jobs for running them independently.
Tagging has uses beyond separating scenarios into groups based on how fast they are:
When they should be run: on @checkin, @hourly, @daily
What external dependencies they have: @local, @database, @network
Level: @functional, @system, @smoke
Parameters:
We could use as well parameters to enrich our FTests for different use cases/inputs. Here is an example
Compounds
Compound steps (calling steps from steps) could help us to factorize better our steps:
Given /^(.*) is logged in$/ do |name| Given "the user #{name} exists" Given "I log in as #{name}" end