summaryrefslogtreecommitdiffstats
path: root/test/ninja
diff options
context:
space:
mode:
authorDaniel Moody <dmoody256@gmail.com>2022-05-04 18:25:08 (GMT)
committerDaniel Moody <dmoody256@gmail.com>2022-05-04 18:25:08 (GMT)
commitc02ab1bee6d00fb3a166f19eb56427f93f333480 (patch)
tree4c8b0df78b56ff72bc9ec2ee7faba446aa7af1c4 /test/ninja
parentbd64d6256fb866a676435fdffeefcaed054b7e1c (diff)
downloadSCons-c02ab1bee6d00fb3a166f19eb56427f93f333480.zip
SCons-c02ab1bee6d00fb3a166f19eb56427f93f333480.tar.gz
SCons-c02ab1bee6d00fb3a166f19eb56427f93f333480.tar.bz2
optimized test
Diffstat (limited to 'test/ninja')
-rw-r--r--test/ninja/mingw_depfile_format.py13
-rw-r--r--test/ninja/ninja_test_sconscripts/sconstruct_mingw_depfile_format7
2 files changed, 2 insertions, 18 deletions
diff --git a/test/ninja/mingw_depfile_format.py b/test/ninja/mingw_depfile_format.py
index 39f2876..583fe66 100644
--- a/test/ninja/mingw_depfile_format.py
+++ b/test/ninja/mingw_depfile_format.py
@@ -66,18 +66,7 @@ test.run(stdout=None)
test.must_contain_all_lines(test.stdout(), ['Generating: build.ninja'])
test.must_contain_all(test.stdout(), 'Executing:')
test.must_contain_all(test.stdout(), 'ninja%(_exe)s -f' % locals())
-
-Path(test.workpath('test_header.h')).touch()
-original_mtime = Path(test.workpath('out' + _exe)).lstat().st_mtime
-
-# only generate the ninja file
-program = test.workpath('run_ninja_env.bat') if IS_WINDOWS else ninja_bin
-test.run(program=program, arguments=['-v'], stdout=None)
-
-new_mtime = Path(test.workpath('out' + _exe)).lstat().st_mtime
-
-if original_mtime == new_mtime:
- test.fail_test(message="Reason: Ninja failed to rebuild the output when the header changed.")
+test.must_contain(test.workpath('build.ninja'), 'deps = gcc')
test.pass_test()
diff --git a/test/ninja/ninja_test_sconscripts/sconstruct_mingw_depfile_format b/test/ninja/ninja_test_sconscripts/sconstruct_mingw_depfile_format
index 26da918..f3856df 100644
--- a/test/ninja/ninja_test_sconscripts/sconstruct_mingw_depfile_format
+++ b/test/ninja/ninja_test_sconscripts/sconstruct_mingw_depfile_format
@@ -1,10 +1,5 @@
SetOption('experimental','ninja')
DefaultEnvironment(tools=[])
-env = Environment(tools=['mingw', 'textfile'])
+env = Environment(tools=['mingw'])
env.Tool('ninja')
-
-env.Textfile('main.c', ['#include "test_header.h"', 'int main(){return header_func();}'])
-env.Textfile('test_header.h', ['#pragma once', 'int header_func(){return 0;}'])
-
-env.Program('out', 'main.c') \ No newline at end of file