Skip to content
Snippets Groups Projects
Commit 639cc5f5 authored by Guilhem Saurel's avatar Guilhem Saurel
Browse files

robotpkg-test-rc.py: testing sot-core & sot-dynamic-pinocchio for v2

functionnal changes:
- run `git pull` instead of `git clone` if the directory has already
  been cloned
- add the `category` in the configuration tuple, as pinocchio is in
  `math` and not in `wip`
- run `git submodule update` after branch change

style changes:
- constants can go out of the main class
- make more use of the standard library:
    - argparse to improve cli options
    - logging to define verbosity level
    - pathlib used more, instead of os.path
    - use newer functions from subprocess, instead of Popen
- add `env_join` helper to generate environment variables
- add cli options:
    - robotpkg_root directory
    - -v / --verbose to increment logging level
    - -d / --delete to completely remove robotpkg_root
    - -c / --clean to remove robotpkg_base & work.$HOSTNAME directories
    - --robotpkg_git & --robotpkg_wip_git to use a custom one
    - --conf to append a custom robotpkg.conf file
- use the `get` method of dict to provide a default
- use the `cwd` parameter of subprocess functions instead of using
  os.chdir
- use the `universal_newlines` of subprocess function instead of
  decoding bytes
- use the `with` statement to perform I/O operations
- use the `/` operator to join Path
- remove things related to Bash
- use $ROBOTPKG_BASE instead of $ROBOTPKG_ROOT/install
- actually run the script only `if __name__ == '__main__'`
parent 72829a31
No related branches found
No related tags found
1 merge request!4Update robotpkg-test-rc.py for pinocchio v2.0.0 tests
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment