#!/bin/sh
export THEANO_FLAGS=base_compiledir='$AUTOPKGTEST_TMP/theanocache'
testroot="/usr/lib/python3/dist-packages/theano"
conftestdir=$PWD
#Avoid importing the source tree
cd $AUTOPKGTEST_TMP

#A random-ish selection of upstream's tests, as the whole thing takes hours
python3 -m pytest -s -v --confcutdir=$conftestdir $testroot/tensor/tests/test_basic.py::Test_add $testroot/tensor/tests/test_subtensor.py::Test_subtensor::test_noncontiguous_idx $testroot/tensor/tests/test_opt.py::test_log1p $testroot/tensor/tests/test_blas.py::TestSgemv::test_a_strides $testroot/tensor/tests/test_nlinalg.py::test_SVD::test_svd $testroot/tensor/tests/test_shared_randomstreams.py::Test_SharedRandomStreams::test_binomial_vector $testroot/tensor/tests/test_mpi $testroot/tensor/nnet/tests/test_sigm.py::UltraFastSigmoidTester $testroot/tensor/signal/tests/test_pool.py::TestDownsampleFactorMax::test_max_pool_2d_2D $testroot/sparse/tests/test_opt.py::test_sd_csc $testroot/scan_module/tests/test_scan.py::Test_Scan::test_scan_merge_nodes $testroot/scalar/tests/test_basic.py::test_logical $testroot/gof/tests/test_opt.py::TestPatternOptimizer::test_ambiguous $testroot/d3viz/tests/test_d3viz.py::TestD3Viz::test_mlp_profiled $testroot/compile/tests/test_pfunc.py::Test_pfunc::test_param_strict $testroot/typed_list/tests/test_basic.py::test_remove $testroot/tests/test_printing.py::test_debugprint $testroot/tests/test_gradient.py::test_dxdx
