diff options
author | William Deegan <bill@baddogconsulting.com> | 2021-04-13 21:28:01 (GMT) |
---|---|---|
committer | William Deegan <bill@baddogconsulting.com> | 2021-04-13 21:28:01 (GMT) |
commit | d9a3a4781c45a7d5551440cca508debc6166822c (patch) | |
tree | f637f01eda75d92908683fb50b5ac03a8637b3f6 | |
parent | 8fa2fe1cf7367970611180d8146803bb333d4c7b (diff) | |
download | SCons-d9a3a4781c45a7d5551440cca508debc6166822c.zip SCons-d9a3a4781c45a7d5551440cca508debc6166822c.tar.gz SCons-d9a3a4781c45a7d5551440cca508debc6166822c.tar.bz2 |
Add --experimental=ninja
-rw-r--r-- | SCons/Script/SConsOptions.py | 4 | ||||
-rw-r--r-- | test/option/option--experimental.py | 7 |
2 files changed, 6 insertions, 5 deletions
diff --git a/SCons/Script/SConsOptions.py b/SCons/Script/SConsOptions.py index 0233703..c8c9cf8 100644 --- a/SCons/Script/SConsOptions.py +++ b/SCons/Script/SConsOptions.py @@ -39,7 +39,7 @@ SUPPRESS_HELP = optparse.SUPPRESS_HELP diskcheck_all = SCons.Node.FS.diskcheck_types() -experimental_features = {'warp_speed', 'transporter'} +experimental_features = {'warp_speed', 'transporter', 'ninja'} def diskcheck_convert(value): @@ -734,7 +734,7 @@ def Parser(version): op.add_option('--experimental', dest='experimental', action='callback', - default={}, # empty set + default=set(), # empty set type='str', # choices=experimental_options+experimental_features, callback =experimental_callback, diff --git a/test/option/option--experimental.py b/test/option/option--experimental.py index 0f0e9ec..2e06dc3 100644 --- a/test/option/option--experimental.py +++ b/test/option/option--experimental.py @@ -35,12 +35,13 @@ test.file_fixture('fixture/SConstruct__experimental', 'SConstruct') tests = [ ('.', []), - ('--experimental=all', ['transporter', 'warp_speed']), + ('--experimental=ninja', ['ninja']), + ('--experimental=all', ['ninja', 'transporter', 'warp_speed']), ('--experimental=none', []), ] for args, exper in tests: - read_string = """All Features=transporter,warp_speed + read_string = """All Features=ninja,transporter,warp_speed Experimental=%s """ % (exper) test.run(arguments=args, @@ -49,7 +50,7 @@ Experimental=%s test.run(arguments='--experimental=warp_drive', stderr="""usage: scons [OPTION] [TARGET] ... -SCons Error: option --experimental: invalid choice: 'warp_drive' (choose from 'all','none','transporter','warp_speed') +SCons Error: option --experimental: invalid choice: 'warp_drive' (choose from 'all','none','ninja','transporter','warp_speed') """, status=2) |