From 151630b58ee4fa51c8554a1185c2374988f57594 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Jan=20H=C3=B6nig?= <jan.hoenig@fau.de>
Date: Thu, 11 Nov 2021 19:17:55 +0100
Subject: [PATCH] Fixing CI part 3

---
 MANIFEST.in             | 3 +++
 setup.cfg               | 1 +
 tests/test_benchmark.py | 8 +++++---
 3 files changed, 9 insertions(+), 3 deletions(-)
 create mode 100644 MANIFEST.in

diff --git a/MANIFEST.in b/MANIFEST.in
new file mode 100644
index 0000000..ef395db
--- /dev/null
+++ b/MANIFEST.in
@@ -0,0 +1,3 @@
+include README.md
+include LICENSE.md
+include pystencils_benchmark/templates/*
diff --git a/setup.cfg b/setup.cfg
index 827f3b3..4063797 100644
--- a/setup.cfg
+++ b/setup.cfg
@@ -14,6 +14,7 @@ packages = pystencils_benchmark
 install_requires =
     jinja2 >= 3.0
     pystencils >= 0.3.4
+include_package_data = true
 tests_require = pytest
 python_requires = >3.8
 setup_requires = setuptools >= 40.0
diff --git a/tests/test_benchmark.py b/tests/test_benchmark.py
index 0026944..63be8ff 100755
--- a/tests/test_benchmark.py
+++ b/tests/test_benchmark.py
@@ -7,7 +7,8 @@ from pathlib import Path
 
 
 def test_generate():
-    path = Path.cwd()
+    path = Path.cwd() / 'test'
+    path.mkdir(parents=True, exist_ok=True)
     a, b, c = ps.fields(a=np.ones(4000000), b=np.ones(4000000), c=np.ones(4000000))
     alpha = sp.symbols('alpha')
 
@@ -23,5 +24,6 @@ def test_generate():
 
     for compiler in [Compiler.GCC, Compiler.GCCdebug, Compiler.Clang]:
         generate_benchmark([kernel_vadd, kernel_daxpy], path, compiler=compiler)
-        subprocess.run(['make'])
-        subprocess.run([f'./benchmark-{compiler.name}', '100'])
+        subprocess.run(['make', '-C', f'{path}'], check=True)
+        subprocess.run([f'{path}/benchmark-{compiler.name}', '10'], check=True)
+
-- 
GitLab