Skip to content

Commit 11a219e

Browse files
authored
Merge pull request #3 from olezhabobrov/olezhabobrov/slawa4s/sarif_generation
Olezhabobrov/slawa4s/sarif generation
2 parents a673ae9 + 4d4f174 commit 11a219e

File tree

761 files changed

+6604
-6604
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

761 files changed

+6604
-6604
lines changed

.github/workflows/build-utbot.yml

Lines changed: 47 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -12,14 +12,15 @@ jobs:
1212
outputs:
1313
matrix: ${{ steps.set-matrix.outputs.matrix }}
1414
steps:
15-
- name: Read config from matrix.json
15+
- name: Checkout repository
1616
uses: actions/checkout@v2
1717
- id: set-matrix
18+
name: Read config from matrix.json
1819
run: |
1920
TASKS=$(echo $(cat .github/workflows/matrix.json) | sed 's/ //g' )
2021
echo "::set-output name=matrix::$TASKS"
2122
22-
build:
23+
build-utbot-and-run-unit-tests:
2324
needs: matrix-prep
2425
strategy:
2526
matrix: ${{ fromJson(needs.matrix-prep.outputs.matrix) }}
@@ -41,17 +42,55 @@ jobs:
4142
uses: actions/checkout@v2
4243
with:
4344
submodules: recursive
44-
- name: build UTBot and run unit tests
45+
- name: Build UTBot
46+
run: |
47+
export VERSION=$(date '+%Y.%m').$GITHUB_RUN_NUMBER
48+
export RUN_INFO=$GITHUB_SERVER_URL/$GITHUB_REPOSITORY/actions/runs/$GITHUB_RUN_ID
49+
echo $RUN_INFO
50+
chmod +x docker/action-scripts/build-utbot.sh
51+
./docker/action-scripts/build-utbot.sh
52+
- name: Run Unit Tests
4553
run: |
46-
chmod +x docker/action-scripts/build-and-unit-tests.sh
47-
./docker/action-scripts/build-and-unit-tests.sh
48-
shell: bash
54+
chmod +x docker/action-scripts/unit-tests.sh
55+
./docker/action-scripts/unit-tests.sh
4956
- uses: actions/upload-artifact@v2
5057
if: failure()
5158
with:
5259
name: UTBot unit tests logs
5360
path: server/build/logs
54-
- name: build VSCode plugin
61+
62+
build-utbot-and-run-integration-tests:
63+
needs: matrix-prep
64+
strategy:
65+
matrix: ${{ fromJson(needs.matrix-prep.outputs.matrix) }}
66+
runs-on: ubuntu-${{ matrix.OPERATING_SYSTEM_TAG }}
67+
container:
68+
image: ghcr.io/unittestbot/utbotcpp/base_env:${{ matrix.DOCKER_TAG }}
69+
credentials:
70+
username: ${{ github.actor }}
71+
password: ${{ secrets.GITHUB_TOKEN }}
72+
env:
73+
UTBOT_ALL: /utbot_distr
74+
UTBOT_INSTALL_DIR: /utbot_distr/install
75+
GRPC_PATH: /utbot_distr/install
76+
CLI_PATH: /utbot_distr/cli
77+
DOCKER_TAG: ${{ matrix.DOCKER_TAG }}
78+
ARTIFACT_DIR: utbot-artifact
79+
steps:
80+
- name: Checkout repository
81+
uses: actions/checkout@v2
82+
with:
83+
submodules: recursive
84+
85+
- name: build UTBot
86+
run: |
87+
export VERSION=$(date '+%Y.%m').$GITHUB_RUN_NUMBER
88+
export RUN_INFO=$GITHUB_SERVER_URL/$GITHUB_REPOSITORY/actions/runs/$GITHUB_RUN_ID
89+
chmod +x docker/action-scripts/build-utbot.sh
90+
./docker/action-scripts/build-utbot.sh
91+
- name: Run Integration Tests
5592
run: |
5693
chmod +x docker/action-scripts/build-vsix.sh
57-
./docker/action-scripts/build-vsix.sh
94+
./docker/action-scripts/build-vsix.sh
95+
chmod +x docker/action-scripts/integration-tests.sh
96+
./docker/action-scripts/integration-tests.sh
Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,22 @@
1+
name: Add issue to projects
2+
3+
on:
4+
issues:
5+
types:
6+
- opened
7+
8+
jobs:
9+
add-to-project:
10+
name: Add issue to projects
11+
runs-on: ubuntu-latest
12+
steps:
13+
- name: Add issue to UTBot C/C++ project
14+
uses: actions/add-to-project@main
15+
with:
16+
project-url: https://github.com/orgs/UnitTestBot/projects/1
17+
github-token: ${{ secrets.COPY_ISSUE_TO_PROJECT }}
18+
- name: Add issue to UTBot Management
19+
uses: actions/add-to-project@main
20+
with:
21+
project-url: https://github.com/orgs/UnitTestBot/projects/5
22+
github-token: ${{ secrets.COPY_ISSUE_TO_PROJECT }}

.github/workflows/matrix.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
{
22
"include": [
33
{
4-
"DOCKER_TAG": "02-02-2022",
4+
"DOCKER_TAG": "24-03-2022",
55
"OPERATING_SYSTEM_TAG": "18.04",
66
"LLVM_VERSION_MAJOR": "10"
77
}

.github/workflows/publish-base-env.yml

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,9 +12,10 @@ jobs:
1212
outputs:
1313
matrix: ${{ steps.set-matrix.outputs.matrix }}
1414
steps:
15-
- name: Read config from matrix.json
15+
- name: Checkout repository
1616
uses: actions/checkout@v2
1717
- id: set-matrix
18+
name: Read config from matrix.json
1819
run: |
1920
TASKS=$(echo $(cat .github/workflows/matrix.json) | sed 's/ //g' )
2021
echo "::set-output name=matrix::$TASKS"

.github/workflows/publish-utbot.yml

Lines changed: 17 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -3,17 +3,21 @@ name: Publish UTBot as an archive
33
on:
44
workflow_dispatch:
55
push:
6-
branches: [main]
6+
tags:
7+
- '[0-9][0-9][0-9][0-9].[0-1][0-9].[0-9]+'
8+
branches:
9+
- main
710

811
jobs:
912
matrix-prep:
1013
runs-on: ubuntu-latest
1114
outputs:
1215
matrix: ${{ steps.set-matrix.outputs.matrix }}
1316
steps:
14-
- name: Read config from matrix.json
17+
- name: Checkout repository
1518
uses: actions/checkout@v2
1619
- id: set-matrix
20+
name: Read config from matrix.json
1721
run: |
1822
TASKS=$(echo $(cat .github/workflows/matrix.json) | sed 's/ //g' )
1923
echo "::set-output name=matrix::$TASKS"
@@ -24,9 +28,6 @@ jobs:
2428
matrix: ${{ fromJson(needs.matrix-prep.outputs.matrix) }}
2529
runs-on: ubuntu-${{ matrix.OPERATING_SYSTEM_TAG }}
2630
env:
27-
# Environment for the job and for the container is, sadly, duplicated
28-
# https://github.com/docker/compose/issues/1837
29-
VERSION: ${{ format('1.0.{0}', github.run_number) }}
3031
ARTIFACT_DIR: utbot-artifact
3132
container:
3233
image: ghcr.io/unittestbot/utbotcpp/base_env:${{ matrix.DOCKER_TAG }}
@@ -38,7 +39,6 @@ jobs:
3839
UTBOT_INSTALL_DIR: /utbot_distr/install
3940
GRPC_PATH: /utbot_distr/install
4041
CLI_PATH: /utbot_distr/cli
41-
VERSION: ${{ format('1.0.{0}', github.run_number) }}
4242
ARTIFACT_DIR: utbot-artifact
4343
steps:
4444
- name: Checkout repository
@@ -51,6 +51,15 @@ jobs:
5151
./docker/action-scripts/build-vsix.sh
5252
- name: build UTBot
5353
run: |
54+
re="^[0-9]{4}\.[0-1][0-9]\.[0-9]+$"
55+
if [[ $GITHUB_REF_NAME =~ $re ]]; then
56+
export VERSION=$GITHUB_REF_NAME
57+
echo "ARTIFACT_NAME=release-$VERSION" >> $GITHUB_ENV
58+
else
59+
export VERSION=$(date '+%Y.%m').$GITHUB_RUN_NUMBER
60+
echo "ARTIFACT_NAME=dev-$VERSION" >> $GITHUB_ENV
61+
fi
62+
export RUN_INFO=$GITHUB_SERVER_URL/$GITHUB_REPOSITORY/actions/runs/$GITHUB_RUN_ID
5463
chmod +x docker/action-scripts/build-utbot.sh
5564
./docker/action-scripts/build-utbot.sh
5665
shell: bash
@@ -60,7 +69,7 @@ jobs:
6069
./docker/action-scripts/prepare-ubuntu-release.sh
6170
- uses: actions/upload-artifact@v2
6271
with:
63-
name: utbot-release-${{ env.VERSION }}
72+
name: utbot-${{ env.ARTIFACT_NAME }}
6473
path: ${{ env.ARTIFACT_DIR }}
6574

6675
auto_installation_check:
@@ -73,7 +82,7 @@ jobs:
7382
uses: actions/download-artifact@v2
7483
- name: Installation check
7584
run: |
76-
cd $(find . -name utbot-release* -type d -print | head -n1)
85+
cd $(find . -name utbot-* -type d -print | head -n1)
7786
chmod +x ./unpack_and_run_utbot.sh
7887
../integration-tests/installation_checks/automated_install_checks.sh ./utbot_distr.tar.gz
7988
../integration-tests/installation_checks/clean.sh

.gitmodules

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
[submodule "klee"]
22
path = submodules/klee
3-
url = https://github.com/olezhabobrov/klee.git
4-
branch = sarif
3+
url = https://github.com/UnitTestBot/klee.git
4+
branch = olezhkabobrov/err_in_sarif
55
[submodule "Bear"]
66
path = submodules/Bear
77
url = https://github.com/UnitTestBot/Bear.git

0 commit comments

Comments
 (0)