You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
ljleppan
changed the title
Replace URL pointing at production with example.com URLs in test resources
Replace URLs pointing at production with example.com URLs in test resources
Sep 4, 2015
We currently have multiple JSON files we use as test resources (see f.ex. here). Many of these files contain URLs that point to current production systems (example). For the purposes of this task, also consider any staging environments "production", since we have no reason to interact with them during unit tests.
To prevent accidents (sending diffs to the spyware server during tests, submitting exercises to TMC server by accident), these should be replaced with safe alternatives. The safe alternatives can take the form of either localhost URLs or -- perhaps preferably -- URLs pointing at http://www.example.com. The preference for example.com is due to the fact that localhost could theoretically point to some system (f.ex. WireMock) while any URL pointing at example.com can be instantly recognized as a placeholder value.
In practice the task would be to go over these JSON files and change all URLs pointing to tmc.mooc.fi or other such production environments with something that can cause no damage and then fixing the tests that break as a result.
No description provided.
The text was updated successfully, but these errors were encountered: