mirror of
				https://git.launchpad.net/~ubuntu-release/britney/+git/britney2-ubuntu
				synced 2025-10-25 05:34:04 +00:00 
			
		
		
		
	
		
			
				
	
	
		
			36 lines
		
	
	
		
			740 B
		
	
	
	
		
			Bash
		
	
	
		
			Executable File
		
	
	
	
	
			
		
		
	
	
			36 lines
		
	
	
		
			740 B
		
	
	
	
		
			Bash
		
	
	
		
			Executable File
		
	
	
	
	
| #!/bin/bash
 | |
| 
 | |
| set -e
 | |
| 
 | |
| err=0
 | |
| 
 | |
| PYTEST_COV_OPTIONS=
 | |
| BRITNEY=./britney.py
 | |
| 
 | |
| git clone https://salsa.debian.org/debian/britney2-tests.git britney2-tests
 | |
| 
 | |
| if [ "x$1" = "x--with-coverage" ]; then
 | |
|     PYTEST_COV_OPTIONS="--cov-branch --cov --cov-report="
 | |
|     BRITNEY=./ci/britney-coverage.sh
 | |
|     TEST_FLAGS=
 | |
| else
 | |
|     TEST_FLAGS=nocodestyle
 | |
| fi
 | |
| 
 | |
| export TEST_FLAGS
 | |
| 
 | |
| py.test-3 -v $PYTEST_COV_OPTIONS || err=$?
 | |
| 
 | |
| echo
 | |
| britney2-tests/bin/runtests "$BRITNEY" britney2-tests/t test-out || err=$?
 | |
| 
 | |
| if [ "x$1" = "x--with-coverage" ]; then
 | |
|     python3-coverage report -m
 | |
|     echo
 | |
|     python3-coverage html -d coverage
 | |
|     mkdir codestyle
 | |
|     pycodestyle --config=setup.cfg britney.py  britney2  --show-source --count > codestyle/codestyle.txt || :
 | |
| fi
 | |
| 
 | |
| exit $err
 |