Merge lp:~sbaldassin/ubuntu-system-tests/close_apps into lp:ubuntu-system-tests
Status: | Rejected |
---|---|
Rejected by: | Santiago Baldassin |
Proposed branch: | lp:~sbaldassin/ubuntu-system-tests/close_apps |
Merge into: | lp:ubuntu-system-tests |
Diff against target: |
126 lines (+16/-26) 4 files modified
ubuntu_system_tests/helpers/autopilot/__init__.py (+2/-17) ubuntu_system_tests/helpers/context.py (+7/-1) ubuntu_system_tests/tests/base.py (+5/-8) ubuntu_system_tests/tests/test_calculator.py (+2/-0) |
To merge this branch: | bzr merge lp:~sbaldassin/ubuntu-system-tests/close_apps |
Related bugs: |
Reviewer | Review Type | Date Requested | Status |
---|---|---|---|
platform-qa-bot | continuous-integration | Approve | |
Sergio Cazzolato | Pending | ||
Canonical Platform QA Team | Pending | ||
Review via email: mp+294860@code.launchpad.net |
Commit message
Refactor in the way the system tests uses the context and clean the created resources
Description of the change
This change includes:
Moving the shared context from a global variable shared across modules to an object that's initialized for every test class. This allows us to
- have a context that's independent from class to class
- change the context values depending on the test class: i.e retry_times
Remove the reference to addCleanup added in the shared context which forced us to duplicate work like cleaning the clean up queue which is already taken care in the TestCase constructor. Moreover that reference brakes the class structure by exposing a class method across python modules
Using the addCleanup method already exposed to the tests by extending from BaseUbuntuSyste
Removing the cleanup from the get_proxy methods which had two issues:
if we failed to get the proxy object then the cleanup was never updated
we were manipulating the test context in a method that was just supposed to return a proxy object
Unmerged revisions
- 387. By Santiago Baldassin
-
fixing flake 8 issue
- 386. By Santiago Baldassin
-
Moving shared context to a context that's independent for every test
PASSED: Continuous integration, rev:387 /platform- qa-jenkins. ubuntu. com/job/ ubuntu- system- tests-ci/ 156/ /platform- qa-jenkins. ubuntu. com/job/ build-wily- amd64-package/ 214 /platform- qa-jenkins. ubuntu. com/job/ build-wily- amd64-package/ 214/artifact/ work/output/ *zip*/output. zip /platform- qa-jenkins. ubuntu. com/job/ build-wily- i386-package/ 214 /platform- qa-jenkins. ubuntu. com/job/ build-wily- i386-package/ 214/artifact/ work/output/ *zip*/output. zip /platform- qa-jenkins. ubuntu. com/job/ generic- update- mp/188/ console
https:/
Executed test runs:
SUCCESS: https:/
deb: https:/
SUCCESS: https:/
deb: https:/
None: https:/
Click here to trigger a rebuild: /platform- qa-jenkins. ubuntu. com/job/ ubuntu- system- tests-ci/ 156/rebuild
https:/