From e6b679c3832dc828a72ff51e6c74a5dcfa2b2370 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Stanis=C5=82aw=20Malinowski?= <56644812+stan-dot@users.noreply.github.com> Date: Thu, 4 Apr 2024 08:32:19 +0100 Subject: [PATCH] delete config (#408) --- config/adsim.yaml | 8 -------- config/bl38p.yaml | 11 ----------- config/bl45p.yaml | 8 -------- config/defaults.yaml | 15 --------------- tests/test_config.py | 12 +----------- 5 files changed, 1 insertion(+), 53 deletions(-) delete mode 100644 config/adsim.yaml delete mode 100644 config/bl38p.yaml delete mode 100644 config/bl45p.yaml delete mode 100644 config/defaults.yaml diff --git a/config/adsim.yaml b/config/adsim.yaml deleted file mode 100644 index 61071c742..000000000 --- a/config/adsim.yaml +++ /dev/null @@ -1,8 +0,0 @@ -env: - sources: - - kind: dodal - module: dodal.adsim - - kind: planFunctions - module: dls_bluesky_core.plans - - kind: planFunctions - module: dls_bluesky_core.stubs diff --git a/config/bl38p.yaml b/config/bl38p.yaml deleted file mode 100644 index b7dbf28f6..000000000 --- a/config/bl38p.yaml +++ /dev/null @@ -1,11 +0,0 @@ -env: - sources: - - kind: dodal - module: dodal.beamlines.p38 - - kind: planFunctions - module: dls_bluesky_core.plans - - kind: planFunctions - module: dls_bluesky_core.stubs - data_writing: - visit_directory: /dls/p38/data/2023/cm33874-1 - group_name: BL38P diff --git a/config/bl45p.yaml b/config/bl45p.yaml deleted file mode 100644 index 355011993..000000000 --- a/config/bl45p.yaml +++ /dev/null @@ -1,8 +0,0 @@ -env: - sources: - - kind: dodal - module: dodal.beamlines.p45 - - kind: planFunctions - module: dls_bluesky_core.plans - - kind: planFunctions - module: dls_bluesky_core.stubs diff --git a/config/defaults.yaml b/config/defaults.yaml deleted file mode 100644 index 757e8cc74..000000000 --- a/config/defaults.yaml +++ /dev/null @@ -1,15 +0,0 @@ -env: - sources: - - kind: deviceFunctions - module: blueapi.startup.example_devices - - kind: planFunctions - module: blueapi.startup.example_plans - - kind: planFunctions - module: dls_bluesky_core.plans - - kind: planFunctions - module: dls_bluesky_core.stubs -stomp: - host: localhost - port: 61613 -logging: - level: "INFO" diff --git a/tests/test_config.py b/tests/test_config.py index fd692746c..cb446ea40 100644 --- a/tests/test_config.py +++ b/tests/test_config.py @@ -6,7 +6,7 @@ import pytest from pydantic import BaseModel, Field -from blueapi.config import ApplicationConfig, BasicAuthentication, ConfigLoader +from blueapi.config import BasicAuthentication, ConfigLoader from blueapi.utils import InvalidConfigError @@ -119,16 +119,6 @@ def test_error_thrown_if_schema_does_not_match_yaml(nested_config_yaml: Path) -> loader.load() -def test_example_config_yaml_gives_same_config_as_model(default_yaml: Path): - loader = ConfigLoader(ApplicationConfig) - default_config = loader.load() - - loader.use_values_from_yaml(default_yaml) - yaml_config = loader.load() - - assert default_config == yaml_config - - @mock.patch.dict(os.environ, {"FOO": "bar"}, clear=True) def test_auth_from_env(): auth = BasicAuthentication(username="${FOO}", passcode="baz")