mirror of
https://github.com/yonaskolb/XcodeGen.git
synced 2026-03-18 20:02:25 +00:00
Updating spec loading tests for build scripts with input and output file lists
This commit is contained in:
@@ -1663,11 +1663,13 @@
|
||||
files = (
|
||||
);
|
||||
inputFileListPaths = (
|
||||
inputList.xcfilelist,
|
||||
);
|
||||
inputPaths = (
|
||||
);
|
||||
name = MyScript;
|
||||
outputFileListPaths = (
|
||||
outputList.xcfilelist,
|
||||
);
|
||||
outputPaths = (
|
||||
);
|
||||
|
||||
@@ -112,6 +112,10 @@ targets:
|
||||
- name: MyScript
|
||||
script: |
|
||||
echo "You ran a script!"
|
||||
inputFileLists:
|
||||
- inputList.xcfilelist
|
||||
outputFileLists:
|
||||
- outputList.xcfilelist
|
||||
|
||||
App_watchOS:
|
||||
type: application.watchapp2
|
||||
|
||||
@@ -438,6 +438,8 @@ class SpecLoadingTests: XCTestCase {
|
||||
["path": "script.sh"],
|
||||
["script": "shell script\ndo thing", "name": "myscript", "inputFiles": ["file", "file2"], "outputFiles": ["file", "file2"], "shell": "bin/customshell", "runOnlyWhenInstalling": true],
|
||||
["script": "shell script\ndo thing", "name": "myscript", "inputFiles": ["file", "file2"], "outputFiles": ["file", "file2"], "shell": "bin/customshell", "showEnvVars": false],
|
||||
["script": "shell script\nwith file lists", "name": "myscript", "inputFileLists": ["inputList.xcfilelist"], "outputFileLists": ["outputList.xcfilelist"], "shell": "bin/customshell", "runOnlyWhenInstalling": true],
|
||||
["script": "shell script\nwith file lists", "name": "myscript", "inputFileLists": ["inputList.xcfilelist"], "outputFileLists": ["outputList.xcfilelist"], "shell": "bin/customshell", "showEnvVars": false]
|
||||
]
|
||||
target["preBuildScripts"] = scripts
|
||||
target["postCompileScripts"] = scripts
|
||||
@@ -447,6 +449,8 @@ class SpecLoadingTests: XCTestCase {
|
||||
BuildScript(script: .path("script.sh")),
|
||||
BuildScript(script: .script("shell script\ndo thing"), name: "myscript", inputFiles: ["file", "file2"], outputFiles: ["file", "file2"], shell: "bin/customshell", runOnlyWhenInstalling: true, showEnvVars: true),
|
||||
BuildScript(script: .script("shell script\ndo thing"), name: "myscript", inputFiles: ["file", "file2"], outputFiles: ["file", "file2"], shell: "bin/customshell", runOnlyWhenInstalling: false, showEnvVars: false),
|
||||
BuildScript(script: .script("shell script\nwith file lists"), name: "myscript", inputFileLists: ["inputList.xcfilelist"], outputFileLists: ["outputList.xcfilelist"], shell: "bin/customshell", runOnlyWhenInstalling: true, showEnvVars: true),
|
||||
BuildScript(script: .script("shell script\nwith file lists"), name: "myscript", inputFileLists: ["inputList.xcfilelist"], outputFileLists: ["outputList.xcfilelist"], shell: "bin/customshell", runOnlyWhenInstalling: false, showEnvVars: false),
|
||||
]
|
||||
|
||||
let parsedTarget = try Target(name: "test", jsonDictionary: target)
|
||||
|
||||
Reference in New Issue
Block a user