def METHOD_NAME(self):
    """Test overriding a subst with an environment variable"""
    env = PartialConfigEnvironment(self._objdir())
    env.write_vars(config)
    self.assertEqual(env.substs["MOZ_SUBST_1"], "1")
    self.assertEqual(env.substs["CPP"], "cpp")
    # Reset the environment and set some environment variables.
    env = PartialConfigEnvironment(env.topobjdir)
    os.environ["MOZ_SUBST_1"] = "subst 1 environ"
    os.environ["CPP"] = "cpp environ"
    # The MOZ_SUBST_1 should be overridden by the environment, while CPP is
    # a special variable and should not.
    self.assertEqual(env.substs["MOZ_SUBST_1"], "subst 1 environ")
    self.assertEqual(env.substs["CPP"], "cpp")