(self)
| 401 | assert cfg.get('auth') is None |
| 402 | |
| 403 | def test_load_config_unknown_keys(self): |
| 404 | folder = tempfile.mkdtemp() |
| 405 | self.addCleanup(shutil.rmtree, folder) |
| 406 | dockercfg_path = os.path.join(folder, 'config.json') |
| 407 | config = { |
| 408 | 'detachKeys': 'ctrl-q, ctrl-u, ctrl-i' |
| 409 | } |
| 410 | with open(dockercfg_path, 'w') as f: |
| 411 | json.dump(config, f) |
| 412 | |
| 413 | cfg = auth.load_config(dockercfg_path) |
| 414 | assert dict(cfg) == {'auths': {}} |
| 415 | |
| 416 | def test_load_config_invalid_auth_dict(self): |
| 417 | folder = tempfile.mkdtemp() |
nothing calls this directly
no test coverage detected