# Contributor: Iztok Fister, Jr. <iztok@iztok-jr-fister.eu>
# Maintainer: Iztok Fister, Jr. <iztok@iztok-jr-fister.eu>
pkgname=py3-niaarmts
pkgver=0.2.0
pkgrel=0
pkgdesc="Time series numerical association rule mining variants"
url="https://github.com/firefly-cpp/NiaARMTS"
arch="noarch"
license="MIT"
depends="python3 py3-niapy py3-pandas"
checkdepends="py3-pytest-xdist"
makedepends="py3-gpep517 py3-poetry-core"
subpackages="$pkgname-pyc"
source="https://github.com/firefly-cpp/NiaARMTS/archive/$pkgver/niaarmts-$pkgver.tar.gz"
builddir="$srcdir/NiaARMTS-$pkgver"

build() {
	gpep517 build-wheel \
		--wheel-dir .dist \
		--output-fd 3 3>&1 >&2
}

check() {
	python3 -m venv --clear --without-pip --system-site-packages .testenv
	.testenv/bin/python3 -m installer .dist/*.whl
	.testenv/bin/python3 -m pytest -n auto -k 'not test_metrics'
}

package() {
	python3 -m installer -d "$pkgdir" \
		.dist/niaarmts-$pkgver-py3-none-any.whl

}

sha512sums="
9f4245e2958acfeac8ba906d7eb9654d411aea5c2815456720368a83d3da5875e8be8e27293bf43d20d43c80f62e4a7e1aa335c4ae2feb140679e027b5cad96b  niaarmts-0.2.0.tar.gz
"
