Also: Add an Environment spec helper class that swaps out global variables to simulate running code in different environments for the replication specs.