| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
|
|
|
| |
Minor maintenance to drop a regex group in a few tests (including in
a test framework test) which allowed for two different exception
messages: one belongs to very old Pythons which are no longer
supported by SCons.
Signed-off-by: Mats Wichmann <mats@linux.com>
|
|
|
|
|
|
| |
Fiddled formatting a bit.
Signed-off-by: Mats Wichmann <mats@linux.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Processing changed a bit - some lines can now be joined instead of
split (if the usage part is short so the combination will still fit).
Dropped the "Ingored for compatibility" chunk from the printout.
The usage: message was changed as it didn't mention variables. A number
of tests expected the exact value of that line, and so were updated.
Updated docstrings (for the API docs).
Signed-off-by: Mats Wichmann <mats@linux.com>
|
|
|
|
|
|
|
|
|
|
| |
The linter identified that warnings was unused in hash-format.py
The linter found that the skip_test function call was using 2 space indentation (not sure how I managed to do that).
Warning was originally added as hash-format gave a warning on ALLOWED_HASH_FORMATS != default
That was changed to instead test the different cases directly.
option--config.py skips the test if the default algorithm is not MD5 as the hashes used are OS-specific,
and supporting it in FIPS mode would be difficult. It's better to just skip this testcase in FIPS mode instead as
this specific test is different in that regard to the other FIPS-enabled tests.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Modified failing tests to use the new defaulted .sconsign database based on the hash algorithm
For MD5, default database will be .sconsign.dblite
For other algorithms the default will be .sconsign_<hashname>.dblite.
For all cases where the user changes the hash algorithm used, the database will be .sconsign_<hashname>.dblite (including md5)
For sub-scons directories it remains as .sconsign
Also added unit-tests for Util.py for the new hash default changes.
It's difficult to setup a fips-compliant platform using containers, and instead we mock that.
option--config uses multiple types of hash algorithms so was skipped.
Removed one f-string (python 3.5 doesn't support those)
Corrupt.py is using an explicit .sconsign so that was left as-is, and only the parent default .sconsign was changed for work test 1.
A fetch-database name option was added to the testing framework.
The unlink_sconsignfile was not updated as no usages of it were found.
|
|
|
|
|
|
|
|
| |
Tweaked some tests which directly set values for _exe, _obj,
which are available from the framework. Done for consistency,
none of these were doing these wrong.
Signed-off-by: Mats Wichmann <mats@linux.com>
|
|
|
|
| |
set. Fix version tests to work with updated scons --version output. (Date format changed)
|
|\
| |
| | |
Change warnings behavior of missing SConscript
|
| |
| |
| |
| |
| |
| |
| | |
If SConscript() is called with must_exist=False, accept the user's
will without issuing a warning about the file being missing.
Signed-off-by: Mats Wichmann <mats@linux.com>
|
|/ |
|
| |
|
| |
|
| |
|
| |
|
| |
|
|
|
|
| |
normal organization.
|
|\ |
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
A line is now emitted showing sconsign sync time if --debug=time
Some calls to time.time replaced with time.perf_counter, where the
objective was to time sections of code (i.e. where there wasn't
an actual need to get time-since-epoch) - Python recommends this
as getting the best-available timer.
Signed-off-by: Mats Wichmann <mats@linux.com>
|
| |
| |
| |
| |
| |
| |
| | |
1. Fix failure finding UserError.
2. Fix bad string formatting.
3. Add test case covering passing an invalid hash format.
4. Remove blake2b, as I haven't tested it. We can add it some day if people want it.
|
| |
| |
| |
| | |
Only thing left is to pick a hash format based on the sconsign database name.
|
| |
| |
| |
| |
| |
| | |
This was requested in the code review. The sconsign database file name is still
.sconsign.dblite if the hash format is not overridden, but if it is, the name
will be something like .sconsign_sha256.dblite.
|
|\ \
| |/ |
|
| | |
|
| | |
|
| | |
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Eliminate unneeded imports, and a few unneeded statements -
usually "pass" where it is not syntactically needed.
A couple of import try blocks were eliminated or changed
when they're "cannot happen" due to current floor Python version.
Signed-off-by: Mats Wichmann <mats@linux.com>
|
| |
| |
| |
| |
| | |
1. Remove unnecessary writes of f1.in and f2.in. The former is already in the dir fixture and the latter is unused.
2. Untabify SConstruct file.
|
|/
|
|
|
|
|
| |
This change adds support for a new --hash-format parameter that can be used to
override the default hash format used by SCons. The default remains MD5, but
this allows consumers to opt into SHA1, SHA256, or any other hash algorithm
offered by their implementation of hashlib.
|
|
|
|
|
|
|
|
|
|
|
|
| |
* Some Py2/Py3 compat blocks were simplified to Py3 only
* some sequences of define-cleaup-function + atexit.register
were changed to use the decorator (this works if func needs to
take no arguments)
* Lightly update a bunch of docstrings in TestCmd, and reformat
a few places, towards the style we're generally using now.
* call_python() in TestCmdTests was modernized to use subprocess.run
Signed-off-by: Mats Wichmann <mats@linux.com>
|
|
|
|
|
|
|
|
| |
test.verbose_set() enables verbose mode, can be a useful
debugging aid. Shouldn't be left in in production tests,
as it creates noise in the test log.
Signed-off-by: Mats Wichmann <mats@linux.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
A couple of minor reformats along the way, most prominently, in tests,
if being edited anyway, make sure the docstring most tests have is
actually the docstring (sometimes the __revision__ line came before,
which makes the string not be the docstring).
Snuck in some minor framework changes that were orphaned when another
draft PR was not needed: this almost all docstring changes, the
functional part is using casefold instead of lower in a match func -
a slightly better approach which is now possible that Py2 compatibility
is not needed.
Signed-off-by: Mats Wichmann <mats@linux.com>
|
| |
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
+ Rename to action-timestamps (from action_timestamps) for
consistency with other compound word options.
+ Put manpage entry in alphabetical order.
+ Describe what option does and shorten it (refers to debug=time
instead of duplicating it)
+ Change prints a bit (and tests to match)
+ Show scons version where added.
+ Slight adjustment to manpage introduction to debug options.
Along the way, fixes a lingering tag mismatch from an earlier
documentation PR.
Updates PR#3456
Signed-off-by: Mats Wichmann <mats@linux.com>
|
| |
|
|
|
|
| |
Started from scratch, removing copy of debug-time.py test.
|
|
|
|
|
|
| |
"action_timestamps"
As per PR review
|
| |
|
| |
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
"for i in range(len(foo))" idiom changed to iterate directly over lists
instead of indexing them. zip() generates the iterator in the case with
two lists. reversed() used for the Windows drive-letter test.
gdbm is not gone, just renamed. change test to find under either name.
Use a context manager for closing StringIO objects opened for capturing
standard I/O streams.
Signed-off-by: Mats Wichmann <mats@linux.com>
|
|
|
|
|
|
|
| |
On a linux host (missing some things that may be on the Travis CI
setup), Py3.8a3 now shows 19 fails, 1048 pass, with 84 Warning: messages.
Signed-off-by: Mats Wichmann <mats@linux.com>
|
| |
|
|
|
|
| |
Signed-off-by: Mats Wichmann <mats@linux.com>
|
|
|
|
| |
Signed-off-by: Mats Wichmann <mats@linux.com>
|
| |
|
|
|
|
| |
see: http://python-notes.curiousefficiency.org/en/latest/python_concepts/import_traps.html#the-name-shadowing-trap
|
| |
|
|\ |
|
| |
| |
| |
| |
| | |
On my windows system, my python is in c:\apps\32\python. Theres a lot of places
where that \32 gets turned into an ascii character and the unit tests don't run.
|