fix mocked environ in tests