File: run-unit-test

package info (click to toggle)
pyensembl 2.3.13-2
  • links: PTS, VCS
  • area: main
  • in suites: trixie
  • size: 600 kB
  • sloc: python: 4,199; makefile: 208; sh: 74
file content (48 lines) | stat: -rw-r--r-- 1,376 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
#!/bin/bash
set -e

pkg=pyensembl
if [ "$AUTOPKGTEST_TMP" = "" ] ; then
  AUTOPKGTEST_TMP=`mktemp -d /tmp/${pkg}-test.XXXXXX`
  trap "rm -rf $AUTOPKGTEST_TMP" 0 INT QUIT ABRT PIPE TERM
fi

cp -a tests/ $AUTOPKGTEST_TMP

cd $AUTOPKGTEST_TMP

export HOME="$AUTOPKGTEST_TMP"

# common.py and data.py are missing from the source tarball in Pypi, but these
# files are present in the Github source code. These files are required to run
# the following tests:
rm tests/test_download_cache.py
rm tests/test_ensembl_gtf.py
rm tests/test_gene_ids.py
rm tests/test_gene_names.py
rm tests/test_gene_objects.py
rm tests/test_id_length.py
rm tests/test_missing_genome_sources.py
rm tests/test_mouse.py
rm tests/test_search.py
rm tests/test_sequence_data.py
rm tests/test_serialization.py
rm tests/test_transcript_ids.py
rm tests/test_transcript_objects.py
rm tests/test_ucsc_gtf.py

# pyensembl is missing a dependency needed to import test data. The test data
# could be added to debian/tests/data or in a multi-source tarball depending
# on the size of data being added. The following tests are affected:
rm tests/test_contigs.py
rm tests/test_exon_id.py
rm tests/test_exon_object.py
rm tests/test_string_representation.py
rm tests/test_timings.py
rm tests/test_transcript_sequences.py
rm tests/test_transcript_support_level.py

for py in $(py3versions -s)
do 
	$py -m pytest tests
done