diff options
author | Christian Kandeler <christian.kandeler@qt.io> | 2018-02-22 11:14:48 +0100 |
---|---|---|
committer | Christian Kandeler <christian.kandeler@qt.io> | 2018-02-22 15:20:07 +0000 |
commit | b2ac794e82c3487411eca68a30b7295ed5315dd6 (patch) | |
tree | 019849a4de271e8431a03f3fe185c2f9521b32a6 /tests/auto/api/testdata | |
parent | edeac6bab66d6fc8d53daf82bc51e145158b1a3d (diff) |
Make autotests mingw-friendlier
Some autotests need to execute processes built earlier in the same test.
With mingw, these need to find libgcc at runtime. Make sure it is
available, either by using "qbs run" or by adding a dependency on the
cpp module in the product that runs the application.
Change-Id: I7f000c3d604a3412049a271b53b5fed4cc7fc54e
Reviewed-by: Jake Petroules <jake.petroules@qt.io>
Diffstat (limited to 'tests/auto/api/testdata')
4 files changed, 12 insertions, 4 deletions
diff --git a/tests/auto/api/testdata/explicitly-depends-on/explicitly-depends-on.qbs b/tests/auto/api/testdata/explicitly-depends-on/explicitly-depends-on.qbs index bbe00083d..0ac4a7463 100644 --- a/tests/auto/api/testdata/explicitly-depends-on/explicitly-depends-on.qbs +++ b/tests/auto/api/testdata/explicitly-depends-on/explicitly-depends-on.qbs @@ -6,22 +6,27 @@ Project { CppApplication { name: "compiler" files: ["compiler.cpp"] + Group { + fileTagsFilter: ["application"] + fileTags: ["compiler"] + } } Product { name: "p" type: ["mytype"] Depends { name: "compiler" } + Depends { name: "cpp" } Rule { inputs: ["mytype.in"] - explicitlyDependsOn: ["application"] + explicitlyDependsOn: ["compiler"] Artifact { filePath: input.fileName + ".out" fileTags: product.type } prepare: { - var compiler = explicitlyDependsOn["application"][0].filePath; + var compiler = explicitlyDependsOn["compiler"][0].filePath; var cmd = new Command(compiler, [input.filePath, output.filePath]); cmd.description = "compiling " + input.fileName; cmd.highlight = "compiler"; @@ -31,7 +36,7 @@ Project { Rule { multiplex: true - explicitlyDependsOn: ["application"] + explicitlyDependsOn: ["compiler"] Artifact { filePath: "compiler-name.txt" fileTags: product.type @@ -40,7 +45,7 @@ Project { var nameCmd = new JavaScriptCommand(); nameCmd.description = "writing compiler name"; nameCmd.sourceCode = function() { - var compiler = explicitlyDependsOn["application"][0].filePath; + var compiler = explicitlyDependsOn["compiler"][0].filePath; var file = new TextFile(output.filePath, TextFile.WriteOnly); file.write("compiler file name: " + FileInfo.baseName(compiler)); file.close(); diff --git a/tests/auto/api/testdata/process-result/process-result.qbs b/tests/auto/api/testdata/process-result/process-result.qbs index ee1ded76a..2aaf0626e 100644 --- a/tests/auto/api/testdata/process-result/process-result.qbs +++ b/tests/auto/api/testdata/process-result/process-result.qbs @@ -9,6 +9,7 @@ Project { name: "app-caller" type: "mytype" Depends { name: "app" } + Depends { name: "cpp" } property bool redirectStdout property bool redirectStderr property int argument diff --git a/tests/auto/api/testdata/tool-in-module/use-outside-project/modules/thetool/thetool.qbs b/tests/auto/api/testdata/tool-in-module/use-outside-project/modules/thetool/thetool.qbs index 36c2cbdc7..d9bd47003 100644 --- a/tests/auto/api/testdata/tool-in-module/use-outside-project/modules/thetool/thetool.qbs +++ b/tests/auto/api/testdata/tool-in-module/use-outside-project/modules/thetool/thetool.qbs @@ -2,6 +2,7 @@ import qbs import qbs.FileInfo Module { + Depends { name: "cpp" } Group { name: "thetool binary" files: FileInfo.cleanPath(FileInfo.joinPaths(path, "..", "..", diff --git a/tests/auto/api/testdata/tool-in-module/use-within-project/use-within-project.qbs b/tests/auto/api/testdata/tool-in-module/use-within-project/use-within-project.qbs index ecfef55c3..13b2bb819 100644 --- a/tests/auto/api/testdata/tool-in-module/use-within-project/use-within-project.qbs +++ b/tests/auto/api/testdata/tool-in-module/use-within-project/use-within-project.qbs @@ -12,6 +12,7 @@ Project { } Export { + Depends { name: "cpp" } Rule { multiplex: true explicitlyDependsOn: ["thetool.thetool"] |