Skip to content

Commit

Permalink
Merge remote-tracking branch 'origin/bird-import-proto' into HEAD
Browse files Browse the repository at this point in the history
  • Loading branch information
Markuu-s committed Dec 28, 2024
2 parents c5aaf0a + a9e7fde commit d7ca9ba
Show file tree
Hide file tree
Showing 315 changed files with 15,822 additions and 9,352 deletions.
27 changes: 7 additions & 20 deletions .github/workflows/docker-image.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,24 +14,11 @@ jobs:
- name: Run clang-format style check
uses: jidicula/[email protected]
with:
clang-format-version: '10'
clang-format-version: '18'
exclude-regex: .*\.proto


build-image-builder:
needs: formatting-check
runs-on: ubuntu-latest
timeout-minutes: 30
steps:
- uses: actions/checkout@v3
- name: Build the yanetplatform/builder
run: |
cd image
# todo
build-unittest:
needs: build-image-builder
needs: formatting-check
runs-on: ubuntu-latest
container:
image: yanetplatform/builder-lite
Expand All @@ -51,8 +38,8 @@ jobs:
retention-days: 1

build-autotest:
needs: build-image-builder
runs-on: builder
needs: formatting-check
runs-on: ubuntu-latest
container:
image: yanetplatform/builder-lite
steps:
Expand All @@ -72,7 +59,7 @@ jobs:
retention-days: 1

build:
needs: build-image-builder
needs: formatting-check
runs-on: ubuntu-latest
container:
image: yanetplatform/builder-lite
Expand All @@ -87,7 +74,7 @@ jobs:

build-ubuntu1804:
name: build (Ubuntu 18.04)
needs: build-image-builder
needs: formatting-check
runs-on: ubuntu-latest
container:
image: yanetplatform/builder_ubuntu18.04-lite
Expand Down Expand Up @@ -117,7 +104,7 @@ jobs:
autotest-001_one_port:
name: 001_one_port
needs: build-autotest
runs-on: autotest
runs-on: ubuntu-latest
container:
image: yanetplatform/builder-lite
steps:
Expand Down
9 changes: 9 additions & 0 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,15 @@ jobs:
uses: actions/checkout@v4
with:
submodules: recursive
- name: version
run: |
export YANET_VERSION=${{github.ref_name}}
export YANET_VERSION=${YANET_VERSION}
export YANET_VERSION_MAJOR=${YANET_VERSION%.*}
export YANET_VERSION_MINOR=${YANET_VERSION#*.}
export YANET_VERSION_REVISION=${{github.run_number}}
export YANET_VERSION_HASH=${{github.sha}}
export YANET_VERSION_CUSTOM=stable
- name: Docker meta
id: meta
uses: docker/metadata-action@v5
Expand Down
26 changes: 26 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,7 @@ docker pull yanetplatform/builder
Add alias for run commands on docker:
```
alias yanet-builder="docker run --rm -it -v /run/yanet:/run/yanet -v \$PWD:/project yanetplatform/builder"
(for Mac: alias yanet-builder="docker run --platform linux/amd64 --rm -it -v /run/yanet:/run/yanet -v \$PWD:/project yanetplatform/builder")
```

Once setup `build_autotest` directory:
Expand All @@ -59,6 +60,31 @@ For more information about the autotests run:
```
yanet-builder ./autotest/yanet-autotest-run.py -h
```

## Running Unit Tests

To run the unit tests for the project, follow these steps:

Setup the build directory for unittest targeting:
```sh
meson setup -Dtarget=unittest build_unittest
```
Next, compile the project within the setup build directory:

```sh
meson compile -C build_unittest
```

After compilation, run all the unit tests with:

```sh
meson test -C build_unittest
```
- To view more detailed output, you can run the tests with -v flag:

```sh
meson test -C build_unittest -v
```
## Dependencies
- [DPDK](https://github.com/DPDK/dpdk)
- [JSON](https://github.com/nlohmann/json)
Expand Down
Loading

0 comments on commit d7ca9ba

Please sign in to comment.