fixes #5451 feat(nimbus): All review_urls should link to simple-review (#5846)

Because

* The simple-review UI is now on prod

This commit

* Changes the review_url to always return simple-review RS URL
This commit is contained in:
Kate Hudson 2021-07-07 16:38:30 -04:00 коммит произвёл GitHub
Родитель 852b46ebb0
Коммит d46008c5ae
Не найден ключ, соответствующий данной подписи
Идентификатор ключа GPG: 4AEE18F83AFDEB23
2 изменённых файлов: 2 добавлений и 17 удалений

Просмотреть файл

@ -335,8 +335,7 @@ class NimbusExperiment(NimbusConstants, FilterMixin, models.Model):
base_url=settings.KINTO_ADMIN_URL,
collection_path="#/buckets/main-workspace/collections",
collection=self.application_config.rs_experiments_collection,
# TODO: Remove IS_STAGING https://github.com/mozilla/experimenter/issues/5451
review_path="simple-review" if settings.IS_STAGING else "records",
review_path="simple-review",
)
def delete_branches(self):

Просмотреть файл

@ -500,9 +500,8 @@ class TestNimbusExperiment(TestCase):
),
)
def test_review_url_stage_should_return_simple_review_url(self):
def test_review_url_should_return_simple_review_url(self):
with override_settings(
IS_STAGING=True,
KINTO_ADMIN_URL="https://settings-writer.stage.mozaws.net/v1/admin/",
):
expected = "https://settings-writer.stage.mozaws.net/v1/admin/#/buckets/main-workspace/collections/nimbus-desktop-experiments/simple-review" # noqa E501
@ -514,7 +513,6 @@ class TestNimbusExperiment(TestCase):
def test_review_url_stage_should_return_simple_review_url_without_slash(self):
with override_settings(
IS_STAGING=True,
KINTO_ADMIN_URL="http://localhost:8888/v1/admin",
):
expected = "http://localhost:8888/v1/admin#/buckets/main-workspace/collections/nimbus-desktop-experiments/simple-review" # noqa E501
@ -524,18 +522,6 @@ class TestNimbusExperiment(TestCase):
)
self.assertEqual(experiment.review_url, expected)
def test_review_url_prod_should_return_records_url(self):
with override_settings(
IS_STAGING=False,
KINTO_ADMIN_URL="https://settings-writer.prod.mozaws.net/v1/admin",
):
expected = "https://settings-writer.prod.mozaws.net/v1/admin#/buckets/main-workspace/collections/nimbus-mobile-experiments/records" # noqa E501
experiment = NimbusExperimentFactory.create_with_lifecycle(
NimbusExperimentFactory.Lifecycles.LAUNCH_APPROVE,
application=NimbusExperiment.Application.FENIX,
)
self.assertEqual(experiment.review_url, expected)
def test_clear_branches_deletes_branches_without_deleting_experiment(self):
experiment = NimbusExperimentFactory.create_with_lifecycle(
NimbusExperimentFactory.Lifecycles.CREATED,