From e5b784736f7ce204f2b3e40869d61aa9fda079af Mon Sep 17 00:00:00 2001 From: Daniel Agar Date: Thu, 4 Jan 2018 22:04:11 -0500 Subject: [PATCH] delete unused cmake/test --- cmake/test/cmake_tester.py | 52 --------------------------- cmake/test/px4_simple_app_correct.txt | 27 -------------- cmake/test/px4_simple_app_input.txt | 4 --- 3 files changed, 83 deletions(-) delete mode 100755 cmake/test/cmake_tester.py delete mode 100644 cmake/test/px4_simple_app_correct.txt delete mode 100644 cmake/test/px4_simple_app_input.txt diff --git a/cmake/test/cmake_tester.py b/cmake/test/cmake_tester.py deleted file mode 100755 index 34bebacb9d..0000000000 --- a/cmake/test/cmake_tester.py +++ /dev/null @@ -1,52 +0,0 @@ -#!/usr/bin/env python -""" -The module facilitates testing in cmake. -It takes a command and a regex for failure ok passing. -It passes if: - * No stderr output. - * Stdout doesn't match failure regex. - * Stdout matches ok regex if given. -""" -from __future__ import print_function -import argparse -import subprocess -import re -import sys - -#pylint: disable=invalid-name - -parser = argparse.ArgumentParser() - -parser.add_argument('cmd') -parser.add_argument('--re-fail') -parser.add_argument('--re-ok') -parser.add_argument('--verbose', '-v', dest='verbose', action='store_true') - -parser.set_defaults(verbose=False) -args = parser.parse_args() - -proc = subprocess.Popen(args.cmd.split(), stdout=subprocess.PIPE, stderr=subprocess.PIPE) -stdout, stderr = proc.communicate() - -if stderr != "": - print(stderr) - sys.exit(1) - -if args.re_fail is not None: - fail_match = re.search(args.re_fail, stdout) - if fail_match is not None: - print(stdout) - sys.exit(1) - -if args.re_ok is not None: - ok_match = re.search(args.re_ok, stdout) - if re.match(args.re_ok, stdout) is None: - print(stdout) - sys.exit(1) - -if args.verbose: - print(stdout) - -sys.exit(0) - -# vim: set et ft=python fenc=utf-8 ff=unix sts=4 sw=4 ts=4 : diff --git a/cmake/test/px4_simple_app_correct.txt b/cmake/test/px4_simple_app_correct.txt deleted file mode 100644 index 9504a8e27a..0000000000 --- a/cmake/test/px4_simple_app_correct.txt +++ /dev/null @@ -1,27 +0,0 @@ -INFO Shell id is 47996278451456 -WARN 1 starting task wkr_high (file /home/jgoppert/git/px4/cmake-Firmware/src/platforms/posix/px4_layer/px4_posix_tasks.cpp line 146) -WARN 54 starting task wkr_low (file /home/jgoppert/git/px4/cmake-Firmware/src/platforms/posix/px4_layer/px4_posix_tasks.cpp line 146) -WARN 100 starting task wkr_hrt (file /home/jgoppert/git/px4/cmake-Firmware/src/platforms/posix/px4_layer/px4_posix_tasks.cpp line 146) -App name: px4 -Enter a command and its args: ----------------------------------- -Running: uorb -Returning: uorb -Enter a command and its args: ----------------------------------- -Running: accelsim -Returning: accelsim -Enter a command and its args: ----------------------------------- -Running: px4_simple_app -Hello Sky! -[px4_simple_app] Got no data within a second -[px4_simple_app] Got no data within a second -[px4_simple_app] Got no data within a second -[px4_simple_app] Got no data within a second -[px4_simple_app] Got no data within a second -Returning: px4_simple_app -Enter a command and its args: ----------------------------------- -Running: shutdown -Shutting down diff --git a/cmake/test/px4_simple_app_input.txt b/cmake/test/px4_simple_app_input.txt deleted file mode 100644 index 29360b9624..0000000000 --- a/cmake/test/px4_simple_app_input.txt +++ /dev/null @@ -1,4 +0,0 @@ -uorb start -accelsim start -px4_simple_app -shutdown