Merge lp:~veebers/juju-ci-tools/migration-add-migrate-back-to-original into lp:juju-ci-tools

Proposed by Christopher Lee
Status: Needs review
Proposed branch: lp:~veebers/juju-ci-tools/migration-add-migrate-back-to-original
Merge into: lp:juju-ci-tools
Prerequisite: lp:~veebers/juju-ci-tools/migration-check-all-model-names
Diff against target: 26 lines (+10/-0)
1 file modified
assess_model_migration.py (+10/-0)
To merge this branch: bzr merge lp:~veebers/juju-ci-tools/migration-add-migrate-back-to-original
Reviewer Review Type Date Requested Status
Curtis Hovey (community) code Approve
Review via email: mp+313333@code.launchpad.net

Description of the change

Add extra test to migrate back to the original controller.

To post a comment you must log in.
Revision history for this message
Curtis Hovey (sinzui) wrote :

Thank you.

review: Approve (code)

Unmerged revisions

1815. By Christopher Lee

Merged migration-superuser-models into migration-add-migrate-back.

1814. By Christopher Lee

Add migrating back to source controller.

1813. By Christopher Lee

Merged migration-log-check-fix into migration-superuser-models.

1812. By Christopher Lee

Fix model name checks.

1811. By Christopher Lee

Get all model names from controller to check against.

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
=== modified file 'assess_model_migration.py'
--- assess_model_migration.py 2016-12-15 09:03:37 +0000
+++ assess_model_migration.py 2016-12-15 09:03:37 +0000
@@ -234,6 +234,10 @@
234 - Migrate that model to the other environment234 - Migrate that model to the other environment
235 - Ensure it's operating as expected235 - Ensure it's operating as expected
236 - Add a new unit to the application to ensure the model is functional236 - Add a new unit to the application to ensure the model is functional
237 - Migrate the model back to the original environment
238 - Note: Test for lp:1607457, lp:1641824
239 - Ensure it's operating as expected
240 - Add a new unit to the application to ensure the model is functional
237241
238 """242 """
239 resource_contents = get_random_string()243 resource_contents = get_random_string()
@@ -244,6 +248,12 @@
244 assert_model_migrated_successfully(248 assert_model_migrated_successfully(
245 migration_target_client, application, resource_contents)249 migration_target_client, application, resource_contents)
246250
251 log.info('Migrating back to original controller.')
252 migrate_back_client = migrate_model_to_controller(
253 migration_target_client, source_client)
254 assert_model_migrated_successfully(
255 migrate_back_client, application, resource_contents)
256
247 migration_target_client.remove_service(application)257 migration_target_client.remove_service(application)
248 log.info('SUCCESS: resources migrated')258 log.info('SUCCESS: resources migrated')
249259

Subscribers

People subscribed via source and target branches