Skip to content

Commit

Permalink
fix tests
Browse files Browse the repository at this point in the history
  • Loading branch information
aszs committed Oct 3, 2024
1 parent 88681c0 commit 8a4be54
Show file tree
Hide file tree
Showing 4 changed files with 6 additions and 6 deletions.
2 changes: 1 addition & 1 deletion tests/examples/decorators-ensemble.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ kind: Ensemble
spec:
service_template:
imports:
- file: spec/decorators-import-template.yaml
- file: import/spec/decorators-import-template.yaml

decorators:
missing:
Expand Down
2 changes: 1 addition & 1 deletion tests/examples/test-workflow-ensemble.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ kind: Ensemble
spec:
service_template:
imports:
- file: spec/service_template.yaml
- file: import/spec/service_template.yaml
- repository: unfurl
file: tosca_plugins/k8s.yaml

Expand Down
2 changes: 1 addition & 1 deletion tests/test_cli.py
Original file line number Diff line number Diff line change
Expand Up @@ -407,7 +407,7 @@ def test_clone_project(self):
runner = CliRunner()
with runner.isolated_filesystem():
specTemplate = os.path.join(
os.path.dirname(__file__), "examples/spec/service_template.yaml"
os.path.dirname(__file__), "examples/import/spec/service_template.yaml"
)
result = runner.invoke(
cli,
Expand Down
6 changes: 3 additions & 3 deletions unfurl/init.py
Original file line number Diff line number Diff line change
Expand Up @@ -798,7 +798,7 @@ def configure(self, remote_source: bool):
f"creating ensemble from {'remote' if remote_source else 'local'} {'' if source_has_ensembles else 'blueprint '}repo at {source_path} with %s",
self.template_vars,
)
assert self.template_vars
assert self.template_vars is not None
if self.options.get("use_deployment_blueprint"):
self.template_vars["deployment_blueprint"] = self.options[
"use_deployment_blueprint"
Expand Down Expand Up @@ -833,7 +833,7 @@ def _create_ensemble_from_template(self, project: Project, destDir, manifestName

specProject = assert_not_none(self.dest_project)
source_project = assert_not_none(self.source_project)
assert self.template_vars
assert self.template_vars is not None
sourceDir = os.path.normpath(
os.path.join(source_project.projectRoot, self.template_vars["sourceDir"])
)
Expand Down Expand Up @@ -1085,7 +1085,7 @@ def set_dest_project_and_path(

def has_existing_ensemble(self, sourceProject: Optional[Project]) -> bool:
if self.source_project is not sourceProject and not self.shared_repo:
assert self.template_vars
assert self.template_vars is not None
if "localEnv" in self.template_vars and os.path.exists(
Path(assert_not_none(self.dest_project).projectRoot)
/ assert_not_none(self.dest_path)
Expand Down

0 comments on commit 8a4be54

Please sign in to comment.