Skip to content

Changes

Summary

  1. scripts/osmotestconfig: remove unused rmtemp arg (details)
  2. scripts/osmotestconfig: fail with trace on 1st err (details)
  3. scripts/osmotestconfig: rmtree: no ignore_errors (details)
  4. scripts/osmotestconfig: copy_config: no copytree (details)
  5. scripts/osmotestconfig: copy_config: tweak mkdir (details)
  6. scripts/osmotestconfig: remove_tmpdir -> shutil.rmtree (details)
Commit ffa8b815b0de5c95d0afe8ed194f1da4141551ec by Oliver Smith
scripts/osmotestconfig: remove unused rmtemp arg

The rmtmp arg to test_all_apps() is always False, remove it.

Change-Id: I469d854cda0a23bbf545953ad2b94666df8e7d04
The file was modified scripts/osmotestconfig.py
Commit 7e04d7535551bd5f8445b8af78fab60c941e5d4b by Oliver Smith
scripts/osmotestconfig: fail with trace on 1st err

Make it easier to figure out why osmotestconfig failed, by failing on
the first error instead of running multiple tests and displaying a
failed error count at the end. Raise an error on failure, so we get a
python trace.

Related: OS#6456
Change-Id: I6a243a2474fbfce63aea8e4418be2f4613808270
The file was modified scripts/osmotestconfig.py
Commit 6c6254aaa0a26c89bda0a810b47ccf34ee6cef85 by Oliver Smith
scripts/osmotestconfig: rmtree: no ignore_errors

Do not ignore errors with shutil.rmtree(). The script expects to be able
to delete the directory, otherwise it will fail later on. So this hides
the original error and leads to a more confusing error later on.

Change-Id: I41616bb27af0d8b7da124ef309cd4a6e53be6597
The file was modified scripts/osmotestconfig.py
Commit ecabb5d1597b9646433e4e946b3543e2846949f1 by Oliver Smith
scripts/osmotestconfig: copy_config: no copytree

In Osmocom git repositories, we have doc/example directories (possibly
with subdirectories), which contain nothing but *.cfg files.

For these directories, the code I'm removing had no effect: it would
copy the whole directory tree of a directory containaing *.cfg files,
but for some reason ignore the *.cfg files. I guess we had a previous
directory structure before, where this made more sense. So essential it
is a mkdir, but this is also not needed since we do a mkdir just below
this.

Furthermore this code caused problems for the related osmo-sgsn patch,
where a *.cfg file is stored in the tests/ dir, because it has to be
slightly different than the file from doc/example. In this case, the
code would actually copy various files, such as Makefile.am, from the
tests directory. This causes problems in "make distcheck", because then
the file permissions are set so that these files cannot removed without
first changing the permissions again. So osmotestconfig.py fails when it
runs copy_config for the second time, trying to remove the temporary
directory.

Related: osmo-sgsn I309807ff0bc125d4653222b2b4ba69ded3bbff70
Change-Id: Ic312d546da1c21f68a80b6a188616ef9bc84f4c6
The file was modified scripts/osmotestconfig.py
Commit 1323cade38d70cc6de4231d3b27d2f3e058640b4 by Oliver Smith
scripts/osmotestconfig: copy_config: tweak mkdir

Run os.mkdir unconditionally, checking if it exists is not needed as we
run shutil.rmtree before.

Change-Id: I555c6d55ee1e288767192f83408a1f132544c928
The file was modified scripts/osmotestconfig.py
Commit bee2f36c96bcca48df0c2c397f29e7d8a879dcf0 by Oliver Smith
scripts/osmotestconfig: remove_tmpdir -> shutil.rmtree

Change-Id: I7cc133b622f863e807da9da04965a0f6f3f6d877
The file was modified scripts/osmotestconfig.py