Skip to content

Commit 9162cea

Browse files
taimoorzaeemsteve-chavez
authored andcommitted
test(io): remove unused config variables from config test
Config variables are tested already via reading the config files in the `configs/` directory. If more are to be tested, it should be done via adding a file in `configs/` and compare it with its associated file in `configs/expected/`. Signed-off-by: Taimoor Zaeem <taimoorzaeem@gmail.com>
1 parent e1d5476 commit 9162cea

1 file changed

Lines changed: 2 additions & 15 deletions

File tree

test/io/test_cli.py

Lines changed: 2 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -195,24 +195,11 @@ def test_stable_config(tmp_path, config, defaultenv):
195195
196196
"""
197197

198-
# Set environment variables that some of the configs expect. Using a
199-
# complex ROLE_CLAIM_KEY to make sure quoting works.
200-
env = {
201-
**defaultenv,
202-
"ROLE_CLAIM_KEY": '."https://www.example.com/roles"[0].value',
203-
"POSTGREST_TEST_SOCKET": "/tmp/postgrest.sock",
204-
"POSTGREST_TEST_PORT": "80",
205-
"JWT_SECRET_FILE": "a_file",
206-
}
207-
208-
# Some configs expect input from stdin, at least on base64.
209-
stdin = b"Y29ubmVjdGlvbl9zdHJpbmc="
210-
211-
dumped = dumpconfig(config, env=env, stdin=stdin)
198+
dumped = dumpconfig(config, env=defaultenv)
212199

213200
tmpconfigpath = tmp_path / "config"
214201
tmpconfigpath.write_text(dumped)
215-
redumped = dumpconfig(tmpconfigpath, env=env)
202+
redumped = dumpconfig(tmpconfigpath, env=defaultenv)
216203

217204
assert dumped == redumped
218205

0 commit comments

Comments
 (0)