Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
21 commits
Select commit Hold shift + click to select a range
1c1a5fd
Add CI steps to create database.
thisismeonmounteverest Dec 7, 2025
f9e54dd
Create MariaDB and test database as part of the test workflow.
thisismeonmounteverest Dec 7, 2025
c46c4db
Update ci.yml
thisismeonmounteverest Dec 7, 2025
21990da
Update .env.test
thisismeonmounteverest Dec 7, 2025
486f5bc
Update ci.yml
thisismeonmounteverest Dec 7, 2025
c420ce7
Update ci.yml
thisismeonmounteverest Dec 7, 2025
5dd06a0
Install dependencies and run encore to create needed files for integr…
thisismeonmounteverest Dec 8, 2025
c1978ad
Update ci.yml
thisismeonmounteverest Dec 8, 2025
025ab3d
Update ci.yml
thisismeonmounteverest Dec 8, 2025
50a3993
Update ci.yml
thisismeonmounteverest Dec 8, 2025
66c1a98
Updating ci.yml to use
thisismeonmounteverest Dec 8, 2025
72e4049
Updating ci.yml to use
thisismeonmounteverest Dec 8, 2025
848556d
Updating ci.yml to use $GITHUB_OUTPUT
thisismeonmounteverest Dec 8, 2025
4897f08
Updating ci.yml to use $GITHUB_OUTPUT
thisismeonmounteverest Dec 8, 2025
4cbfe06
Updating ci.yml to use $GITHUB_OUTPUT
thisismeonmounteverest Dec 8, 2025
3bef258
Ignore SignupController for infection (mutating integration tests is …
thisismeonmounteverest Dec 8, 2025
ca73816
Enabling infection run.
thisismeonmounteverest Dec 8, 2025
df99181
Update ci.yml
thisismeonmounteverest Dec 8, 2025
c533c66
Update ci.yml
thisismeonmounteverest Dec 8, 2025
739d420
Update infection.json5.dist
thisismeonmounteverest Dec 8, 2025
7003d91
Update ci.yml
thisismeonmounteverest Dec 8, 2025
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 4 additions & 4 deletions .env.test
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ MANTICORE_HOST="127.0.0.1"
MANTICORE_PORT="9308"
DB_HOST="127.0.0.1"
DB_PORT="3306"
DB_USER="root"
DB_PASS=""
DB_NAME="bewelcome_test"
DATABASE_URL="mysql://${DB_USER}:${DB_PASS}@${DB_HOST}:${DB_PORT}/${DB_NAME}?serverVersion=10.11.2-MariaDB&charset=utf8mb4"
DB_USER="bewelcome"
DB_PASS="bewelcome"
DB_NAME="bewelcome"
DATABASE_URL="mysql://${DB_USER}:${DB_PASS}@${DB_HOST}:${DB_PORT}/${DB_NAME}?serverVersion=10.11.2-MariaDB&charset=utf8mb4"
74 changes: 52 additions & 22 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ jobs:

- name: Get Composer Cache Directory
id: composer-cache
run: echo "::set-output name=dir::$(composer config cache-files-dir)"
run: echo "dir=$(composer config cache-files-dir)" >> $GITHUB_OUTPUT

- name: Cache dependencies
uses: actions/cache@0400d5f644dc74513175e3cd8d07132dd4860809 # tag=v4.2.4
Expand All @@ -48,8 +48,8 @@ jobs:
- name: Run phpcpd tests
run: vendor/bin/phpcpd src --exclude=src/Entity --exclude=src/Repository

phpunit:
name: PHPUnit
tests:
name: Tests
runs-on: ubuntu-latest
steps:
- name: Checkout
Expand All @@ -64,7 +64,7 @@ jobs:

- name: Get Composer Cache Directory
id: composer-cache
run: echo "::set-output name=dir::$(composer config cache-files-dir)"
run: echo "dir=$(composer config cache-files-dir)" >> $GITHUB_OUTPUT

- name: Cache dependencies
uses: actions/cache@0400d5f644dc74513175e3cd8d07132dd4860809 # tag=v4.2.4
Expand All @@ -77,19 +77,38 @@ jobs:
run: composer install --prefer-dist --no-progress --no-suggest --no-interaction --no-scripts

- name: Run phpunit tests
run: bin/phpunit --coverage-text --coverage-xml=build/logs/phpunit/coverage-xml --coverage-clover=build/logs/phpunit/clover.xml --log-junit=build/logs/phpunit/unit.xml --colors=never --order-by=random --exclude-group=integration
run: bin/phpunit --coverage-text --coverage-xml=build/logs/phpunit/coverage-xml --coverage-clover=build/logs/phpunit/clover.xml --log-junit=build/logs/phpunit/junit.xml --colors=never --order-by=random --exclude-group=integration

# - name: Run Infection tests
# run: vendor/bin/infection --coverage=build/logs/phpunit --min-covered-msi=85 --threads=30
- name: Run Infection tests
run: vendor/bin/infection --skip-initial-tests --coverage=build/logs/phpunit --min-covered-msi=80 --threads=30

# - name: Run Integration tests
# run: bin/phpunit --log-junit=build/logs/phpunit/integration.xml --colors=never --order-by=random --group=integration
- name: Install MariaDB
uses: getong/mariadb-action@v1.11
with:
mysql database: 'bewelcome_test'
mysql user: 'bewelcome'
mysql password: 'bewelcome'

# - uses: actions/upload-artifact@ea165f8d65b6e75b540449e92b4886f43607fa02 # tag=v4.6.2
# if: ${{ always() }}
# with:
# name: infection.log
# path: infection.log
- name: Create test database
run: bin/console test:database:create --env=test

- name: Setup Yarn
uses: threeal/setup-yarn-action@v2.0.0
with:
version: latest
cache: false

- name: Install yarn dependencies and run webpack
run: yarn install --frozen-lock ; yarn encore dev

- name: Run Integration tests
run: bin/phpunit --log-junit=build/logs/phpunit/integration.xml --colors=never --order-by=random --group=integration

- uses: actions/upload-artifact@ea165f8d65b6e75b540449e92b4886f43607fa02 # tag=v4.6.2
if: ${{ always() }}
with:
name: infection.log
path: infection.log

phploc:
name: PHPLoc
Expand All @@ -106,7 +125,7 @@ jobs:

- name: Get Composer Cache Directory
id: composer-cache
run: echo "::set-output name=dir::$(composer config cache-files-dir)"
run: echo "dir=$(composer config cache-files-dir)" >> $GITHUB_OUTPUT

- name: Cache dependencies
uses: actions/cache@0400d5f644dc74513175e3cd8d07132dd4860809 # tag=v4.2.4
Expand Down Expand Up @@ -137,7 +156,7 @@ jobs:

- name: Get Composer Cache Directory
id: composer-cache
run: echo "::set-output name=dir::$(composer config cache-files-dir)"
run: echo "dir=$(composer config cache-files-dir)" >> $GITHUB_OUTPUT

- name: Cache dependencies
uses: actions/cache@0400d5f644dc74513175e3cd8d07132dd4860809 # tag=v4.2.4
Expand Down Expand Up @@ -168,7 +187,7 @@ jobs:
#
# - name: Get Composer Cache Directory
# id: composer-cache
# run: echo "::set-output name=dir::$(composer config cache-files-dir)"
# run: echo "dir=$(composer config cache-files-dir)" >> $GITHUB_OUTPUT
#
# - name: Cache dependencies
# uses: actions/cache@0400d5f644dc74513175e3cd8d07132dd4860809 # tag=v4.2.4
Expand Down Expand Up @@ -198,7 +217,7 @@ jobs:

- name: Get Composer Cache Directory
id: composer-cache
run: echo "::set-output name=dir::$(composer config cache-files-dir)"
run: echo "dir=$(composer config cache-files-dir)" >> $GITHUB_OUTPUT

- name: Cache dependencies
uses: actions/cache@0400d5f644dc74513175e3cd8d07132dd4860809 # tag=v4.2.4
Expand Down Expand Up @@ -228,7 +247,7 @@ jobs:

- name: Get Composer Cache Directory
id: composer-cache
run: echo "::set-output name=dir::$(composer config cache-files-dir)"
run: echo "dir=$(composer config cache-files-dir)" >> $GITHUB_OUTPUT

- name: Cache dependencies
uses: actions/cache@0400d5f644dc74513175e3cd8d07132dd4860809 # tag=v4.2.4
Expand Down Expand Up @@ -258,7 +277,7 @@ jobs:

- name: Get Composer Cache Directory
id: composer-cache
run: echo "::set-output name=dir::$(composer config cache-files-dir)"
run: echo "dir=$(composer config cache-files-dir)" >> $GITHUB_OUTPUT

- name: Cache dependencies
uses: actions/cache@0400d5f644dc74513175e3cd8d07132dd4860809 # tag=v4.2.4
Expand Down Expand Up @@ -288,7 +307,7 @@ jobs:

- name: Get Composer Cache Directory
id: composer-cache
run: echo "::set-output name=dir::$(composer config cache-files-dir)"
run: echo "dir=$(composer config cache-files-dir)" >> $GITHUB_OUTPUT

- name: Cache dependencies
uses: actions/cache@0400d5f644dc74513175e3cd8d07132dd4860809 # tag=v4.2.4
Expand Down Expand Up @@ -322,7 +341,7 @@ jobs:

- name: Get Composer Cache Directory
id: composer-cache
run: echo "::set-output name=dir::$(composer config cache-files-dir)"
run: echo "dir=$(composer config cache-files-dir)" >> $GITHUB_OUTPUT

- name: Cache dependencies
uses: actions/cache@0400d5f644dc74513175e3cd8d07132dd4860809 # tag=v4.2.4
Expand All @@ -341,3 +360,14 @@ jobs:

- name: Run JS security checker
run: yarn audit --groups dependencies











2 changes: 1 addition & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -88,7 +88,7 @@ int-test:
"./bin/phpunit" --log-junit=build/logs/phpunit/junit.xml --colors=never --order-by=random --group=integration

infection: phpunit
"./vendor/bin/infection" --coverage=build/logs/phpunit --min-covered-msi=85 --threads=30
"./vendor/bin/infection" --skip-initial-tests --coverage=build/logs/phpunit --min-covered-msi=80 --threads=30

#behat: encore
# bin/console doctrine:database:create --env=test --if-not-exists
Expand Down
3 changes: 3 additions & 0 deletions infection.json5.dist
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,9 @@
"source": {
"directories": [
"src/Model"
],
"excludes": [
"src/Controller/SignupController"
]
},
"timeout": 30,
Expand Down
Loading