mirror of
https://github.com/kevinveenbirkenbach/computer-playbook.git
synced 2025-08-29 15:06:26 +02:00
Renamed generate commands to build
This commit is contained in:
@@ -9,7 +9,7 @@ import yaml
|
||||
# Adjust path to include cli/ folder
|
||||
sys.path.insert(0, os.path.abspath(os.path.join(os.path.dirname(__file__), "../../../../..", "cli")))
|
||||
|
||||
from cli.generate.role_include import build_dependency_graph, topological_sort, gen_condi_role_incl
|
||||
from cli.build.role_include import build_dependency_graph, topological_sort, gen_condi_role_incl
|
||||
|
||||
class TestGeneratePlaybook(unittest.TestCase):
|
||||
def setUp(self):
|
||||
|
@@ -30,7 +30,7 @@ class TestGenerateDefaultApplications(unittest.TestCase):
|
||||
shutil.rmtree(self.temp_dir)
|
||||
|
||||
def test_script_generates_expected_yaml(self):
|
||||
script_path = Path(__file__).resolve().parent.parent.parent.parent.parent.parent / "cli/generate/defaults/applications.py"
|
||||
script_path = Path(__file__).resolve().parent.parent.parent.parent.parent.parent / "cli/build/defaults/applications.py"
|
||||
|
||||
result = subprocess.run(
|
||||
[
|
||||
|
@@ -45,7 +45,7 @@ class TestGenerateDefaultApplicationsUsers(unittest.TestCase):
|
||||
When a users.yml exists with defined users, the script should inject a 'users'
|
||||
mapping in the generated YAML, mapping each username to a Jinja2 reference.
|
||||
"""
|
||||
script_path = Path(__file__).resolve().parents[5] / "cli" / "generate/defaults/applications.py"
|
||||
script_path = Path(__file__).resolve().parents[5] / "cli" / "build/defaults/applications.py"
|
||||
result = subprocess.run([
|
||||
"python3", str(script_path),
|
||||
"--roles-dir", str(self.roles_dir),
|
||||
|
@@ -7,7 +7,7 @@ import yaml
|
||||
from collections import OrderedDict
|
||||
|
||||
# Add cli/ to import path
|
||||
sys.path.insert(0, os.path.abspath(os.path.join(os.path.dirname(__file__), "../../../../..", "cli/generate/defaults/")))
|
||||
sys.path.insert(0, os.path.abspath(os.path.join(os.path.dirname(__file__), "../../../../..", "cli/build/defaults/")))
|
||||
|
||||
import users
|
||||
|
||||
|
@@ -3,7 +3,7 @@ import tempfile
|
||||
import shutil
|
||||
import os
|
||||
import yaml
|
||||
from cli.generate import graph
|
||||
from cli.build import graph
|
||||
|
||||
|
||||
class TestGraphLogic(unittest.TestCase):
|
||||
|
@@ -3,7 +3,7 @@ import tempfile
|
||||
import shutil
|
||||
import os
|
||||
import json
|
||||
from cli.generate import tree
|
||||
from cli.build import tree
|
||||
|
||||
|
||||
class TestTreeMain(unittest.TestCase):
|
||||
|
Reference in New Issue
Block a user