MCPcopy Create free account
hub / github.com/theskumar/python-dotenv / test_unset_existing_value

Function test_unset_existing_value

tests/test_cli.py:88–95  ·  view source on GitHub ↗
(cli, dotenv_file)

Source from the content-addressed store, hash-verified

86
87
88def test_unset_existing_value(cli, dotenv_file):
89 with open(dotenv_file, "w") as f:
90 f.write("a=b")
91
92 result = cli.invoke(dotenv_cli, ['--file', dotenv_file, 'unset', 'a'])
93
94 assert (result.exit_code, result.output) == (0, "Successfully removed a\n")
95 assert open(dotenv_file, "r").read() == ""
96
97
98def test_unset_non_existent_value(cli, dotenv_file):

Callers

nothing calls this directly

Calls 1

readMethod · 0.80

Tested by

no test coverage detected