From 39b39aed2725ba6f7fa4305939560f3696f50d7f Mon Sep 17 00:00:00 2001 From: Marco Edoardo Santimaria Date: Tue, 7 Oct 2025 10:19:33 +0200 Subject: [PATCH 1/4] Added python unit tests --- .github/workflows/ci-test.yml | 47 +++++++ .gitignore | 3 + CMakeLists.txt | 9 +- bindings/python_bindings.cpp | 9 +- test-requirement.txt | 1 + tests/{ => cpp}/main.cpp | 0 tests/python/test_engine.py | 251 ++++++++++++++++++++++++++++++++++ 7 files changed, 318 insertions(+), 2 deletions(-) create mode 100644 test-requirement.txt rename tests/{ => cpp}/main.cpp (100%) create mode 100644 tests/python/test_engine.py diff --git a/.github/workflows/ci-test.yml b/.github/workflows/ci-test.yml index 0892515..8f3e880 100644 --- a/.github/workflows/ci-test.yml +++ b/.github/workflows/ci-test.yml @@ -122,6 +122,53 @@ jobs: path: ./coverage.xml retention-days: 1 if-no-files-found: error + + python-tests: + name: "Test python bindings" + strategy: + matrix: + on: [ 'ubuntu-24.04', 'macos-15-intel' , 'macos-26' ] + python: [ '3.10', '3.11', '3.12', '3.13' ] + + runs-on: ${{matrix.on}} + env: + INSTALL_PREFIX: "/usr/local" + + steps: + - uses: actions/checkout@v4 + - uses: actions/setup-python@v6 + with: + python-version: ${{matrix.python}} + - name: "Install packages ubuntu" + if: ${{ startsWith(matrix.on, 'ubuntu-') }} + run: sudo apt install -y ninja-build g++ + + - name: "Setup macos runner" + if: ${{ startsWith(matrix.on, 'macos-') }} + uses: Homebrew/actions/setup-homebrew@main + + - name: "Install macos packages" + if: ${{ startsWith(matrix.on, 'macos-') }} + run: brew install ninja gcc cmake + + - name: "Run CMake" + run: | + cmake -DCMAKE_BUILD_TYPE=Release \ + -G Ninja \ + -B ../build \ + -S ${GITHUB_WORKSPACE} + cmake --build ../build -j $(nproc) + sudo cmake --install ../build --prefix $INSTALL_PREFIX + + - name: "Install python test environment" + run: python -m pip install -r ${GITHUB_WORKSPACE}/test-requirement.txt + + - name: "Run python tests" + run: | + export CAPIO_CL_PY_BINDING_PATH=$(realpath $INSTALL_PREFIX/lib/python/py_capio_cl*) + echo "Python module path: $CAPIO_CL_PY_BINDING_PATH" + pytest ${GITHUB_WORKSPACE}/tests/python/test_* + # upload-to-codecov: # name: "Codecov report upload" # needs: [ "unit-tests" , "codespell-check" , "format-check" ] diff --git a/.gitignore b/.gitignore index c020f03..5fafb18 100644 --- a/.gitignore +++ b/.gitignore @@ -1,6 +1,9 @@ # IntelliJ .idea/** cmake-build-*/** +.venv/** +__pycache__/ +*.pyc # Prerequisites *.d diff --git a/CMakeLists.txt b/CMakeLists.txt index 323d916..4bb67c6 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -19,6 +19,7 @@ set(CMAKE_CXX_FLAGS_RELEASE "${CMAKE_CXX_FLAGS_RELEASE} -O3") set(CMAKE_POSITION_INDEPENDENT_CODE ON) include(FetchContent) +include(GNUInstallDirs) ##################################### # Options @@ -98,6 +99,12 @@ if (BUILD_PYTHON_BINDINGS) ${CMAKE_CURRENT_SOURCE_DIR} ) + install(TARGETS ${PYTHON_BIND_NAME} + LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR}/python + ARCHIVE DESTINATION ${CMAKE_INSTALL_LIBDIR}/python + RUNTIME DESTINATION ${CMAKE_INSTALL_BINDIR} + ) + endif () @@ -116,7 +123,7 @@ if (CAPIO_CL_BUILD_TESTS) set(gtest_force_shared_crt ON CACHE BOOL "" FORCE) FetchContent_MakeAvailable(googletest) - add_executable(CAPIO_CL_tests tests/main.cpp) + add_executable(CAPIO_CL_tests tests/cpp/main.cpp) target_link_libraries(CAPIO_CL_tests PRIVATE libcapio_cl diff --git a/bindings/python_bindings.cpp b/bindings/python_bindings.cpp index b1445e7..6525a8f 100644 --- a/bindings/python_bindings.cpp +++ b/bindings/python_bindings.cpp @@ -31,7 +31,7 @@ PYBIND11_MODULE(py_capio_cl, m) { .def("setFileDeps", &capiocl::Engine::setFileDeps) .def("setStoreFileInMemory", &capiocl::Engine::setStoreFileInMemory) .def("setStoreFileInFileSystem", &capiocl::Engine::setStoreFileInFileSystem) - .def("getDirectoryFileCount", &capiocl::Engine::setDirectoryFileCount) + .def("getDirectoryFileCount", &capiocl::Engine::getDirectoryFileCount) .def("getCommitRule", &capiocl::Engine::getCommitRule) .def("getFireRule", &capiocl::Engine::getFireRule) .def("getProducers", &capiocl::Engine::getProducers) @@ -53,6 +53,13 @@ PYBIND11_MODULE(py_capio_cl, m) { return "(&e)) + ">"; }); + m.attr("MODE_UPDATE") = py::str(capiocl::MODE_UPDATE); + m.attr("MODE_NO_UPDATE") = py::str(capiocl::MODE_NO_UPDATE); + m.attr("COMMITTED_ON_CLOSE") = py::str(capiocl::COMMITTED_ON_CLOSE); + m.attr("COMMITTED_ON_FILE") = py::str(capiocl::COMMITTED_ON_FILE); + m.attr("COMMITTED_N_FILES") = py::str(capiocl::COMMITTED_N_FILES); + m.attr("COMMITTED_ON_TERMINATION") = py::str(capiocl::COMMITTED_ON_TERMINATION); + py::class_(m, "Parser", "The CAPIO-CL Parser component.") .def("parse", &capiocl::Parser::parse) .def("__str__", diff --git a/test-requirement.txt b/test-requirement.txt new file mode 100644 index 0000000..ca2a549 --- /dev/null +++ b/test-requirement.txt @@ -0,0 +1 @@ +pytest==8.4.2 \ No newline at end of file diff --git a/tests/main.cpp b/tests/cpp/main.cpp similarity index 100% rename from tests/main.cpp rename to tests/cpp/main.cpp diff --git a/tests/python/test_engine.py b/tests/python/test_engine.py new file mode 100644 index 0000000..dab0f94 --- /dev/null +++ b/tests/python/test_engine.py @@ -0,0 +1,251 @@ +''' +TEST(testpy_capio_clEngine, testAddFileDefault) { + py_capio_cl::Engine engine; +EXPECT_EQ(engine.size(), 0); +engine.newFile("test.dat"); +EXPECT_EQ(engine.size(), 1); +EXPECT_EQ(engine.getCommitRule("test.dat"), py_capio_cl::COMMITTED_ON_TERMINATION); +EXPECT_EQ(engine.getFireRule("test.dat"), py_capio_cl::MODE_UPDATE); +EXPECT_TRUE(engine.getConsumers("test.dat").empty()); +EXPECT_TRUE(engine.getProducers("test.dat").empty()); +EXPECT_FALSE(engine.isPermanent("test.dat")); +EXPECT_FALSE(engine.isExcluded("test.dat")); +EXPECT_TRUE(engine.isFile("test.dat")); +EXPECT_FALSE(engine.isDirectory("test.dat")); +EXPECT_EQ(engine.getDirectoryFileCount("test.dat"), 0); +EXPECT_FALSE(engine.isStoredInMemory("test.dat")); +} +''' + +import os +import importlib.util + +spec = importlib.util.spec_from_file_location("py_capio_cl", os.getenv("CAPIO_CL_PY_BINDING_PATH")) +py_capio_cl = importlib.util.module_from_spec(spec) +spec.loader.exec_module(py_capio_cl) + + +def test_instantiation(): + engine = py_capio_cl.Engine() + assert engine.size() == 0 + + +def test_add_file_default(): + engine = py_capio_cl.Engine() + assert engine.size() == 0 + + engine.newFile("test.dat") + assert engine.size() == 1 + assert engine.getCommitRule("test.dat") == py_capio_cl.COMMITTED_ON_TERMINATION + assert engine.getFireRule("test.dat") == py_capio_cl.MODE_UPDATE + assert engine.getConsumers("test.dat") == [] + assert engine.getProducers("test.dat") == [] + assert not engine.isPermanent("test.dat") + assert not engine.isExcluded("test.dat") + assert engine.isFile("test.dat") + assert not engine.isDirectory("test.dat") + assert engine.getDirectoryFileCount("test.dat") == 0 + assert not engine.isStoredInMemory("test.dat") + + +def test_add_file_default_glob(): + engine = py_capio_cl.Engine() + assert engine.size() == 0 + + engine.newFile("test.*") + assert engine.size() == 1 + assert engine.getCommitRule("test.dat") == py_capio_cl.COMMITTED_ON_TERMINATION + assert engine.getFireRule("test.dat") == py_capio_cl.MODE_UPDATE + assert engine.getConsumers("test.dat") == [] + assert engine.getProducers("test.dat") == [] + assert not engine.isPermanent("test.dat") + assert not engine.isExcluded("test.dat") + assert engine.isFile("test.dat") + assert not engine.isDirectory("test.dat") + assert engine.getDirectoryFileCount("test.dat") == 0 + assert not engine.isStoredInMemory("test.dat") + + +def test_add_file_default_glob_question(): + engine = py_capio_cl.Engine() + assert engine.size() == 0 + + engine.newFile("test.?") + assert engine.size() == 1 + assert engine.getCommitRule("test.1") == py_capio_cl.COMMITTED_ON_TERMINATION + assert engine.getFireRule("test.1") == py_capio_cl.MODE_UPDATE + assert engine.getConsumers("test.1") == [] + assert engine.getProducers("test.1") == [] + assert not engine.isPermanent("test.1") + assert not engine.isExcluded("test.1") + assert engine.isFile("test.1") + assert not engine.isDirectory("test.1") + assert engine.getDirectoryFileCount("test.1") == 0 + assert not engine.isStoredInMemory("test.1") + + +def test_add_file_manually(): + engine = py_capio_cl.Engine() + assert engine.size() == 0 + path = "test.dat" + producers, consumers, file_dependencies = [], [], [] + + engine.add(path, producers, consumers, py_capio_cl.COMMITTED_ON_TERMINATION, + py_capio_cl.MODE_UPDATE, False, False, file_dependencies) + + assert engine.size() == 1 + assert engine.getCommitRule("test.dat") == py_capio_cl.COMMITTED_ON_TERMINATION + assert engine.getFireRule("test.dat") == py_capio_cl.MODE_UPDATE + assert engine.getConsumers("test.dat") == [] + assert engine.getProducers("test.dat") == [] + assert not engine.isPermanent("test.dat") + assert not engine.isExcluded("test.dat") + assert engine.isFile("test.dat") + assert not engine.isDirectory("test.dat") + assert engine.getDirectoryFileCount("test.dat") == 0 + assert not engine.isStoredInMemory("test.dat") + + +def test_add_file_manually_glob(): + engine = py_capio_cl.Engine() + assert engine.size() == 0 + path = "test.*" + producers, consumers, file_dependencies = [], [], [] + + engine.add(path, producers, consumers, py_capio_cl.COMMITTED_ON_TERMINATION, + py_capio_cl.MODE_UPDATE, False, False, file_dependencies) + + assert engine.size() == 1 + assert engine.getCommitRule("test.dat") == py_capio_cl.COMMITTED_ON_TERMINATION + assert engine.getFireRule("test.dat") == py_capio_cl.MODE_UPDATE + assert engine.getConsumers("test.dat") == [] + assert engine.getProducers("test.dat") == [] + assert not engine.isPermanent("test.dat") + assert not engine.isExcluded("test.dat") + assert engine.isFile("test.dat") + assert not engine.isDirectory("test.dat") + assert engine.getDirectoryFileCount("test.dat") == 0 + assert not engine.isStoredInMemory("test.dat") + + +def test_add_file_manually_question(): + engine = py_capio_cl.Engine() + assert engine.size() == 0 + path = "test.?" + producers, consumers, file_dependencies = [], [], [] + + engine.add(path, producers, consumers, py_capio_cl.COMMITTED_ON_CLOSE, + py_capio_cl.MODE_NO_UPDATE, False, False, file_dependencies) + engine.setDirectory("test.?") + engine.setDirectoryFileCount("test.?", 10) + + assert engine.size() == 1 + assert engine.getCommitRule("test.dat") != py_capio_cl.COMMITTED_ON_CLOSE + assert engine.getFireRule("test.dat") != py_capio_cl.MODE_NO_UPDATE + assert engine.getCommitRule("test.1") == py_capio_cl.COMMITTED_ON_CLOSE + assert engine.getFireRule("test.1") == py_capio_cl.MODE_NO_UPDATE + assert engine.getCommitRule("test.2") == py_capio_cl.COMMITTED_ON_CLOSE + assert engine.getFireRule("test.2") == py_capio_cl.MODE_NO_UPDATE + assert engine.isDirectory("test.1") + assert engine.getDirectoryFileCount("test.?") == 10 + assert engine.getDirectoryFileCount("test.3") == 10 + assert engine.getConsumers("test.4") == [] + assert engine.getProducers("test.5") == [] + assert not engine.isPermanent("test.6") + assert not engine.isExcluded("test.7") + assert not engine.isFile("test.8") + assert engine.isDirectory("test.9") + assert engine.getDirectoryFileCount("test.a") == 10 + assert not engine.isStoredInMemory("test.b") + + +def test_add_file_manually_glob_explicit(): + engine = py_capio_cl.Engine() + assert engine.size() == 0 + path = "test.[abc][abc][abc]" + producers, consumers, file_dependencies = [], [], [] + + engine.add(path, producers, consumers, py_capio_cl.COMMITTED_ON_CLOSE, + py_capio_cl.MODE_NO_UPDATE, False, False, file_dependencies) + engine.setDirectory("test.[abc][abc][abc]") + engine.setDirectoryFileCount("test.[abc][abc][abc]", 10) + + assert engine.size() == 1 + assert engine.getCommitRule("test.dat") != py_capio_cl.COMMITTED_ON_CLOSE + assert engine.getFireRule("test.dat") != py_capio_cl.MODE_NO_UPDATE + assert engine.getCommitRule("test.abc") == py_capio_cl.COMMITTED_ON_CLOSE + assert engine.getFireRule("test.aaa") == py_capio_cl.MODE_NO_UPDATE + assert engine.getCommitRule("test.cab") == py_capio_cl.COMMITTED_ON_CLOSE + assert engine.getFireRule("test.bac") == py_capio_cl.MODE_NO_UPDATE + assert engine.getCommitRule("test.ccc") == py_capio_cl.COMMITTED_ON_CLOSE + assert engine.getFireRule("test.aaa") == py_capio_cl.MODE_NO_UPDATE + assert engine.isDirectory("test.bbb") + assert engine.getDirectoryFileCount("test.3") != 10 + + +def test_producers_consumers_file_dependencies(): + engine = py_capio_cl.Engine() + assert engine.size() == 0 + producers = ["A", "B"] + consumers = ["C", "D"] + file_dependencies = ["E", "F"] + + engine.newFile("test.dat") + + engine.addProducer("test.dat", producers[0]) + assert len(engine.getProducers("test.dat")) == 1 + assert engine.isProducer("test.dat", producers[0]) + + engine.addProducer("test.dat", producers[1]) + assert len(engine.getProducers("test.dat")) == 2 + assert engine.isProducer("test.dat", producers[1]) + + engine.addConsumer("test.dat", consumers[0]) + assert len(engine.getConsumers("test.dat")) == 1 + assert engine.isConsumer("test.dat", consumers[0]) + + engine.addConsumer("test.dat", consumers[1]) + assert len(engine.getConsumers("test.dat")) == 2 + assert engine.isConsumer("test.dat", consumers[1]) + + assert engine.getCommitOnFileDependencies("test.dat") == [] + engine.addFileDependency("test.dat", file_dependencies[0]) + assert len(engine.getCommitOnFileDependencies("test.dat")) == 1 + assert engine.getCommitOnFileDependencies("test.dat")[0] == file_dependencies[0] + engine.addFileDependency("test.dat", file_dependencies[1]) + assert len(engine.getCommitOnFileDependencies("test.dat")) == 2 + assert engine.getCommitOnFileDependencies("test.dat")[1] == file_dependencies[1] + + +def test_producers_consumers_file_dependencies_glob(): + engine = py_capio_cl.Engine() + assert engine.size() == 0 + producers = ["A", "B"] + consumers = ["C", "D"] + file_dependencies = ["E", "F"] + + engine.newFile("test.*") + + engine.addProducer("test.dat", producers[0]) + assert len(engine.getProducers("test.dat")) == 1 + assert engine.isProducer("test.dat", producers[0]) + + engine.addProducer("test.dat", producers[1]) + assert len(engine.getProducers("test.dat")) == 2 + assert engine.isProducer("test.dat", producers[1]) + + engine.addConsumer("test.dat", consumers[0]) + assert len(engine.getConsumers("test.dat")) == 1 + assert engine.isConsumer("test.dat", consumers[0]) + + engine.addConsumer("test.dat", consumers[1]) + assert len(engine.getConsumers("test.dat")) == 2 + assert engine.isConsumer("test.dat", consumers[1]) + + assert engine.getCommitOnFileDependencies("test.dat") == [] + engine.addFileDependency("test.dat", file_dependencies[0]) + assert len(engine.getCommitOnFileDependencies("test.dat")) == 1 + assert engine.getCommitOnFileDependencies("test.dat")[0] == file_dependencies[0] + engine.addFileDependency("test.dat", file_dependencies[1]) + assert len(engine.getCommitOnFileDependencies("test.dat")) == 2 + assert engine.getCommitOnFileDependencies("test.dat")[1] == file_dependencies[1] \ No newline at end of file From 574d49dc1485a8e82463175d60674adaa230680f Mon Sep 17 00:00:00 2001 From: Marco Edoardo Santimaria Date: Tue, 7 Oct 2025 11:28:19 +0200 Subject: [PATCH 2/4] Fixed compilation on MacOs --- CMakeLists.txt | 2 +- capiocl.hpp | 4 ++++ src/Engine.cpp | 1 + src/Parser.cpp | 2 +- 4 files changed, 7 insertions(+), 2 deletions(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index 4bb67c6..0fe9d22 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -41,7 +41,7 @@ endif () FetchContent_Declare( simdjson GIT_REPOSITORY https://github.com/simdjson/simdjson.git - GIT_TAG v3.3.0 + GIT_TAG v4.0.7 ) FetchContent_Declare( pybind11 diff --git a/capiocl.hpp b/capiocl.hpp index a537304..21c3bc9 100644 --- a/capiocl.hpp +++ b/capiocl.hpp @@ -9,6 +9,10 @@ #include #include +#ifndef HOST_NAME_MAX +#define HOST_NAME_MAX 1024 +#endif + /** * Compatibility layer for CAPIO logger. */ diff --git a/src/Engine.cpp b/src/Engine.cpp index 7f4557f..98a080c 100644 --- a/src/Engine.cpp +++ b/src/Engine.cpp @@ -2,6 +2,7 @@ #include #include #include +#include void capiocl::Engine::print() const { // First message diff --git a/src/Parser.cpp b/src/Parser.cpp index 3cbe775..4afaf4a 100644 --- a/src/Parser.cpp +++ b/src/Parser.cpp @@ -160,7 +160,7 @@ capiocl::Parser::parse(const std::filesystem::path &source, std::vector streaming_names; std::vector file_deps; long int n_close = -1; - long n_files = -1; + int64_t n_files = -1; bool is_file = true; simdjson::ondemand::array name; From d5238d4c71fd07854f5e1975de21c85672c8aa1f Mon Sep 17 00:00:00 2001 From: Marco Edoardo Santimaria Date: Tue, 7 Oct 2025 11:48:54 +0200 Subject: [PATCH 3/4] Splitted unit tests workflows --- .github/workflows/ci-test.yml | 48 +--------------------- .github/workflows/python-bindings.yml | 57 +++++++++++++++++++++++++++ README.md | 2 + 3 files changed, 60 insertions(+), 47 deletions(-) create mode 100644 .github/workflows/python-bindings.yml diff --git a/.github/workflows/ci-test.yml b/.github/workflows/ci-test.yml index 8f3e880..c8f31ad 100644 --- a/.github/workflows/ci-test.yml +++ b/.github/workflows/ci-test.yml @@ -1,4 +1,4 @@ -name: "CI Tests" +name: "C++ Unit Tests" on: push: branches: @@ -123,52 +123,6 @@ jobs: retention-days: 1 if-no-files-found: error - python-tests: - name: "Test python bindings" - strategy: - matrix: - on: [ 'ubuntu-24.04', 'macos-15-intel' , 'macos-26' ] - python: [ '3.10', '3.11', '3.12', '3.13' ] - - runs-on: ${{matrix.on}} - env: - INSTALL_PREFIX: "/usr/local" - - steps: - - uses: actions/checkout@v4 - - uses: actions/setup-python@v6 - with: - python-version: ${{matrix.python}} - - name: "Install packages ubuntu" - if: ${{ startsWith(matrix.on, 'ubuntu-') }} - run: sudo apt install -y ninja-build g++ - - - name: "Setup macos runner" - if: ${{ startsWith(matrix.on, 'macos-') }} - uses: Homebrew/actions/setup-homebrew@main - - - name: "Install macos packages" - if: ${{ startsWith(matrix.on, 'macos-') }} - run: brew install ninja gcc cmake - - - name: "Run CMake" - run: | - cmake -DCMAKE_BUILD_TYPE=Release \ - -G Ninja \ - -B ../build \ - -S ${GITHUB_WORKSPACE} - cmake --build ../build -j $(nproc) - sudo cmake --install ../build --prefix $INSTALL_PREFIX - - - name: "Install python test environment" - run: python -m pip install -r ${GITHUB_WORKSPACE}/test-requirement.txt - - - name: "Run python tests" - run: | - export CAPIO_CL_PY_BINDING_PATH=$(realpath $INSTALL_PREFIX/lib/python/py_capio_cl*) - echo "Python module path: $CAPIO_CL_PY_BINDING_PATH" - pytest ${GITHUB_WORKSPACE}/tests/python/test_* - # upload-to-codecov: # name: "Codecov report upload" # needs: [ "unit-tests" , "codespell-check" , "format-check" ] diff --git a/.github/workflows/python-bindings.yml b/.github/workflows/python-bindings.yml new file mode 100644 index 0000000..071e7a9 --- /dev/null +++ b/.github/workflows/python-bindings.yml @@ -0,0 +1,57 @@ +name: "Python Bindings Unit Tests" +on: + push: + branches: + - main + pull_request: + branches: + - main +concurrency: + group: build-${{ github.event.pull_request.number || github.ref }} + cancel-in-progress: true +jobs: + python-tests: + name: "Test python bindings" + strategy: + matrix: + on: [ 'ubuntu-24.04', 'macos-15-intel' , 'macos-26' ] + python: [ '3.10', '3.11', '3.12', '3.13' ] + + runs-on: ${{matrix.on}} + env: + INSTALL_PREFIX: "/usr/local" + + steps: + - uses: actions/checkout@v4 + - uses: actions/setup-python@v6 + with: + python-version: ${{matrix.python}} + - name: "Install packages ubuntu" + if: ${{ startsWith(matrix.on, 'ubuntu-') }} + run: sudo apt install -y ninja-build g++ + + - name: "Setup macos runner" + if: ${{ startsWith(matrix.on, 'macos-') }} + uses: Homebrew/actions/setup-homebrew@main + + - name: "Install macos packages" + if: ${{ startsWith(matrix.on, 'macos-') }} + run: brew install ninja gcc cmake + + - name: "Run CMake" + run: | + cmake -DCMAKE_BUILD_TYPE=Release \ + -G Ninja \ + -B ../build \ + -S ${GITHUB_WORKSPACE} + cmake --build ../build -j $(nproc) + sudo cmake --install ../build --prefix $INSTALL_PREFIX + + - name: "Install python test environment" + run: python -m pip install -r ${GITHUB_WORKSPACE}/test-requirement.txt + + - name: "Run python tests" + run: | + export CAPIO_CL_PY_BINDING_PATH=$(realpath $INSTALL_PREFIX/lib/python/py_capio_cl*) + echo "Python module path: $CAPIO_CL_PY_BINDING_PATH" + pytest ${GITHUB_WORKSPACE}/tests/python/test_* \ No newline at end of file diff --git a/README.md b/README.md index d5d03c4..d1fd598 100644 --- a/README.md +++ b/README.md @@ -3,6 +3,8 @@ # CAPIO-CL — Cross-Application Programmable I/O Coordination Language [![CI](https://github.com/High-Performance-IO/CAPIO-CL/actions/workflows/ci-test.yml/badge.svg)](https://github.com/High-Performance-IO/CAPIO-CL/actions/workflows/ci-test.yml) +[![Python Bindings](https://github.com/High-Performance-IO/CAPIO-CL/actions/workflows/python-bindings.yml/badge.svg)](https://github.com/High-Performance-IO/CAPIO-CL/actions/workflows/python-bindings.yml) + ![CMake](https://img.shields.io/badge/CMake-%E2%89%A53.15-blue?logo=cmake&logoColor=white) ![C++](https://img.shields.io/badge/C%2B%2B-%E2%89%A517-blueviolet?logo=c%2B%2B&logoColor=white) From 67b6e5549465d6341aa59e8b21ade1fbadaedd54 Mon Sep 17 00:00:00 2001 From: Marco Edoardo Santimaria Date: Tue, 7 Oct 2025 12:08:29 +0200 Subject: [PATCH 4/4] Updated readme --- .github/workflows/ci-test.yml | 2 +- .github/workflows/python-bindings.yml | 2 +- README.md | 6 ++++-- 3 files changed, 6 insertions(+), 4 deletions(-) diff --git a/.github/workflows/ci-test.yml b/.github/workflows/ci-test.yml index c8f31ad..ab25acf 100644 --- a/.github/workflows/ci-test.yml +++ b/.github/workflows/ci-test.yml @@ -7,7 +7,7 @@ on: branches: - main concurrency: - group: build-${{ github.event.pull_request.number || github.ref }} + group: build-unit-${{ github.event.pull_request.number || github.ref }} cancel-in-progress: true jobs: codespell-check: diff --git a/.github/workflows/python-bindings.yml b/.github/workflows/python-bindings.yml index 071e7a9..32c32d6 100644 --- a/.github/workflows/python-bindings.yml +++ b/.github/workflows/python-bindings.yml @@ -7,7 +7,7 @@ on: branches: - main concurrency: - group: build-${{ github.event.pull_request.number || github.ref }} + group: build-python-${{ github.event.pull_request.number || github.ref }} cancel-in-progress: true jobs: python-tests: diff --git a/README.md b/README.md index d1fd598..1cab53e 100644 --- a/README.md +++ b/README.md @@ -5,10 +5,12 @@ [![CI](https://github.com/High-Performance-IO/CAPIO-CL/actions/workflows/ci-test.yml/badge.svg)](https://github.com/High-Performance-IO/CAPIO-CL/actions/workflows/ci-test.yml) [![Python Bindings](https://github.com/High-Performance-IO/CAPIO-CL/actions/workflows/python-bindings.yml/badge.svg)](https://github.com/High-Performance-IO/CAPIO-CL/actions/workflows/python-bindings.yml) - ![CMake](https://img.shields.io/badge/CMake-%E2%89%A53.15-blue?logo=cmake&logoColor=white) ![C++](https://img.shields.io/badge/C%2B%2B-%E2%89%A517-blueviolet?logo=c%2B%2B&logoColor=white) -![Python Bindings](https://img.shields.io/badge/Python_Bindings-3.8–3.14-darkgreen?style=flat&logo=python&logoColor=white&labelColor=gray) +![Python Bindings](https://img.shields.io/badge/Python_Bindings-3.10–3.14-darkgreen?style=flat&logo=python&logoColor=white&labelColor=gray) + +![Ubuntu](https://img.shields.io/badge/Ubuntu-121212?logo=ubuntu&logoColor=E95420) +![macOS](https://img.shields.io/badge/macOS-121212?logo=apple&logoColor=white) [![DOI](https://img.shields.io/badge/DOI-10.1007%2Fs10766--025--00789--0-%23cc5500?logo=doi&logoColor=white&labelColor=2b2b2b)](https://doi.org/10.1007/s10766-025-00789-0)