Skip to content

Commit fadf0bc

Browse files
committed
config: move all *.yaml files to new config directory
Move all the YAML config files to a new config directory to start separating the configuration data from the kernelci Python package. Update default config path values in kci_* and unit tests accordingly. Signed-off-by: Guillaume Tucker <[email protected]>
1 parent e9a0d64 commit fadf0bc

File tree

10 files changed

+8
-6
lines changed

10 files changed

+8
-6
lines changed
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.

kci_build

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -472,7 +472,7 @@ class cmd_pull_tarball(Command):
472472

473473

474474
if __name__ == '__main__':
475-
opts = parse_opts("kci_build", "build-configs.yaml", globals())
475+
opts = parse_opts("kci_build", "config/build-configs.yaml", globals())
476476
configs = kernelci.config.build.from_yaml(opts.yaml_configs)
477477
status = opts.command(configs, opts)
478478
sys.exit(0 if status is True else 1)

kci_data

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -61,7 +61,7 @@ class cmd_submit(Command):
6161

6262

6363
if __name__ == '__main__':
64-
opts = parse_opts("kci_data", "db-configs.yaml", globals())
64+
opts = parse_opts("kci_data", "config/db-configs.yaml", globals())
6565
configs = kernelci.config.data.from_yaml(opts.yaml_configs)
6666
status = opts.command(configs, opts)
6767
sys.exit(0 if status is True else 1)

kci_rootfs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -146,7 +146,7 @@ class cmd_upload(Command):
146146
#
147147

148148
if __name__ == '__main__':
149-
opts = parse_opts("kci_rootfs", "rootfs-configs.yaml", globals())
149+
opts = parse_opts("kci_rootfs", "config/rootfs-configs.yaml", globals())
150150
configs = kernelci.config.rootfs.from_yaml(opts.yaml_configs)
151151
status = opts.command(configs, opts)
152152
sys.exit(0 if status is True else 1)

kci_test

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -243,9 +243,11 @@ class cmd_submit(Command):
243243

244244
if __name__ == '__main__':
245245
parser = argparse.ArgumentParser("kci_test")
246-
parser.add_argument("--yaml-test-configs", default="test-configs.yaml",
246+
parser.add_argument("--yaml-test-configs",
247+
default="config/test-configs.yaml",
247248
help="Path to the YAML test configs file")
248-
parser.add_argument("--yaml-lab-configs", default="lab-configs.yaml",
249+
parser.add_argument("--yaml-lab-configs",
250+
default="config/lab-configs.yaml",
249251
help="Path to the YAML lab configs file")
250252
parser.add_argument("--settings",
251253
help="Path to the settings file")

tests/test_configs.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44

55
def test_build_configs_parsing():
66
""" Verify build-configs.yaml """
7-
configs = kernelci.config.build.from_yaml("build-configs.yaml")
7+
configs = kernelci.config.build.from_yaml("config/build-configs.yaml")
88
assert len(configs) == 4
99
for key in ['build_configs', 'build_environments', 'fragments', 'trees']:
1010
assert key in configs

0 commit comments

Comments
 (0)