Commit 98911084 authored by Marco Buttu's avatar Marco Buttu
Browse files

Tests

parent 0a8e9158
Loading
Loading
Loading
Loading
+2 −1
Original line number Diff line number Diff line
@@ -42,7 +42,8 @@ MODULES = AntennaBoss \
			Scheduler \
			CalibrationTool \
			NoiseGenerator \
			TotalPower
			TotalPower \
			PySupervisor \


MAKE_FLAGS = "-k"
+64 −0
Original line number Diff line number Diff line
PY_PACKAGES = Supervisor

# CPP UNIT TESTING SETUP
#--------------
# GTEST_HOME=/usr/local/include/gtest
# GMOCK_HOME=/usr/local/include/gmock
# GTEST_LIBS=gtest gtest_main

# USER_INC=-I$(GTEST_HOME) -I$(GMOCK_HOME)
# USER_LIBS=C++ pthread
# END OF CPP UNIT TESTING SETUP
#---------------------

# DEFINE YOUR CPP UNIT TEST EXECUTABLES HERE as:
#
# EXECTUABLES_L = unittest
# unittest_OBJECTS = unittest
# unittest_LIBS = $(GTEST_LIBS) <ComponentNameImpl>

# EXECUTABLES_L = unittest
# unittest_OBJECTS = unittest
# unittest_LIBS = $(GTEST_LIBS) 

# END OF CUSTOMIZATION
# do not edit below this line
#----------------------------

CSOURCENAMES = \
	$(foreach exe, $(EXECUTABLES) $(EXECUTABLES_L), $($(exe)_OBJECTS)) \
	$(foreach rtos, $(RTAI_MODULES) , $($(rtos)_OBJECTS)) \
	$(foreach lib, $(LIBRARIES) $(LIBRARIES_L), $($(lib)_OBJECTS))

MAKEDIRTMP := $(shell searchFile include/acsMakefile)
ifneq ($(MAKEDIRTMP),\#error\#)
   MAKEDIR := $(MAKEDIRTMP)/include
   include $(MAKEDIR)/acsMakefile
endif

# TEST TARGETS

do_pyunit:
	@echo "running python unit tests"
	python -m unittest discover

pyunit: do_pyunit
	@echo " . . . 'pyunit' done"


# TARGETS
# -------
all:	do_all
	@echo " . . . 'all' done" 

clean : clean_all clean_test
	@echo " . . . clean done"

clean_dist : clean_all clean_dist_all clean_test
	@echo " . . . clean_dist done"

man   : do_man 
	@echo " . . . man page(s) done"

install : install_all
	@echo " . . . installation done"
+37 −0
Original line number Diff line number Diff line
********************
How to run the tests
********************

Start ACS::

   $ acsStart

From the Supervisor directory, start the containers::

   $ bin/supervisor_startcontainers.sh

Run all tests::
    
    .. code-block: bash

    $ cd test
    $ python -m unittest discover

Execute a particular test::

.. code-block: bash

    $ python cli/test_cli.py

You can also use coverage::

   $ ./run_coverage

To stop the containers::

   $ bin/supervisor_stopcontainers.sh

To stop ACS::

   $ killACS
   $ acsStop
+0 −0

Empty file added.

+0 −0

Empty file added.

Loading