diff options
author | Mats Wichmann <mats@linux.com> | 2021-11-07 20:39:50 (GMT) |
---|---|---|
committer | Mats Wichmann <mats@linux.com> | 2021-11-11 22:19:53 (GMT) |
commit | 5093d3f59a2d33db040eb04ed4057cbd6bbd71b6 (patch) | |
tree | 8121fc5ac3afc318e8f092e36e4473c44d2bfb91 /test/QT/source-from-ui.py | |
parent | 6051c8beb7bc59f083552e9f431733e93fd56360 (diff) | |
download | SCons-5093d3f59a2d33db040eb04ed4057cbd6bbd71b6.zip SCons-5093d3f59a2d33db040eb04ed4057cbd6bbd71b6.tar.gz SCons-5093d3f59a2d33db040eb04ed4057cbd6bbd71b6.tar.bz2 |
Deprecate the qt tool.
Updates tests to disable the warning that this change enables.
Fix runtest.py to make sure -o logging option captures all the output.
Signed-off-by: Mats Wichmann <mats@linux.com>
Diffstat (limited to 'test/QT/source-from-ui.py')
-rw-r--r-- | test/QT/source-from-ui.py | 57 |
1 files changed, 31 insertions, 26 deletions
diff --git a/test/QT/source-from-ui.py b/test/QT/source-from-ui.py index 7922717..569fbab 100644 --- a/test/QT/source-from-ui.py +++ b/test/QT/source-from-ui.py @@ -1,6 +1,8 @@ #!/usr/bin/env python # -# __COPYRIGHT__ +# MIT License +# +# Copyright The SCons Foundation # # Permission is hereby granted, free of charge, to any person obtaining # a copy of this software and associated documentation files (the @@ -20,9 +22,6 @@ # LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION # OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION # WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. -# - -__revision__ = "__FILE__ __REVISION__ __DATE__ __DEVELOPER__" """ Create .cpp, .h, moc_....cpp from a .ui file. @@ -68,9 +67,9 @@ void useit() { } """) -test.run(arguments = aaa_dll) +test.run(arguments="--warn=no-tool-qt-deprecated " + aaa_dll) -test.up_to_date(options='-n', arguments = aaa_dll) +test.up_to_date(options='--warn=no-tool-qt-deprecated -n', arguments=aaa_dll) test.write('aaa.ui', r""" /* a change */ @@ -82,11 +81,11 @@ test.write('aaa.ui', r""" DLLEXPORT void aaa(void) """) -test.not_up_to_date(options = '-n', arguments = moc) -test.not_up_to_date(options = '-n', arguments = cpp) -test.not_up_to_date(options = '-n', arguments = h) +test.not_up_to_date(options='--warn=no-tool-qt-deprecated -n', arguments=moc) +test.not_up_to_date(options='--warn=no-tool-qt-deprecated -n', arguments=cpp) +test.not_up_to_date(options='--warn=no-tool-qt-deprecated -n', arguments=h) -test.run(arguments = aaa_dll) +test.run(arguments="--warn=no-tool-qt-deprecated " + aaa_dll) test.write('aaa.ui', r""" void aaa(void) @@ -94,28 +93,30 @@ void aaa(void) """) # test that non-existant ui.h files are ignored (as uic does) -test.run(arguments = aaa_dll) +test.run(arguments="--warn=no-tool-qt-deprecated " + aaa_dll) test.write('aaa.ui.h', r""" /* test dependency to .ui.h */ """) -test.run(arguments = aaa_dll) +test.run(arguments="--warn=no-tool-qt-deprecated " + aaa_dll) test.write('aaa.ui.h', r""" /* changed */ """) -test.not_up_to_date(options = '-n', arguments = obj) -test.not_up_to_date(options = '-n', arguments = cpp) -test.not_up_to_date(options = '-n', arguments = h) -test.not_up_to_date(options = '-n', arguments = moc) +test.not_up_to_date(options='--warn=no-tool-qt-deprecated -n', arguments=obj) +test.not_up_to_date(options='--warn=no-tool-qt-deprecated -n', arguments=cpp) +test.not_up_to_date(options='--warn=no-tool-qt-deprecated -n', arguments=h) +test.not_up_to_date(options='--warn=no-tool-qt-deprecated -n', arguments=moc) # clean up -test.run(arguments = '-c ' + aaa_dll) +test.run(arguments="--warn=no-tool-qt-deprecated -c " + aaa_dll) -test.run(arguments = "variant_dir=1 " + - test.workpath('build', aaa_dll) ) +test.run( + arguments="--warn=no-tool-qt-deprecated variant_dir=1 " + + test.workpath('build', aaa_dll) +) test.must_exist(test.workpath('build', moc)) test.must_exist(test.workpath('build', cpp)) @@ -127,8 +128,10 @@ test.must_not_exist(test.workpath(h)) cppContents = test.read(test.workpath('build', cpp), mode='r') test.fail_test(cppContents.find('#include "aaa.ui.h"') == -1) -test.run(arguments = "variant_dir=1 chdir=1 " + - test.workpath('build', aaa_dll) ) +test.run( + arguments="--warn=no-tool-qt-deprecated variant_dir=1 chdir=1 " + + test.workpath('build', aaa_dll) +) test.must_exist(test.workpath('build', moc)) test.must_exist(test.workpath('build', cpp)) @@ -137,12 +140,14 @@ test.must_not_exist(test.workpath(moc)) test.must_not_exist(test.workpath(cpp)) test.must_not_exist(test.workpath(h)) -test.run(arguments = "variant_dir=1 chdir=1 dup=0 " + - test.workpath('build_dup0', aaa_dll) ) +test.run( + arguments="--warn=no-tool-qt-deprecated variant_dir=1 chdir=1 dup=0 " + + test.workpath('build_dup0', aaa_dll) +) -test.must_exist(test.workpath('build_dup0',moc)) -test.must_exist(test.workpath('build_dup0',cpp)) -test.must_exist(test.workpath('build_dup0',h)) +test.must_exist(test.workpath('build_dup0', moc)) +test.must_exist(test.workpath('build_dup0', cpp)) +test.must_exist(test.workpath('build_dup0', h)) test.must_not_exist(test.workpath(moc)) test.must_not_exist(test.workpath(cpp)) test.must_not_exist(test.workpath(h)) |