Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
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
4 changes: 4 additions & 0 deletions .env
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
# Database Configuration
NEO4J_ADDRESS=https://6f72daa1.databases.neo4j.io/
NEO4J_USERNAME=neo4j
NEO4J_PASSWORD=O9lWmptqBgxBOz8NVcTJjgs3cHPyYmsy63ui6Spmw1d0
32 changes: 32 additions & 0 deletions .github/workflows/cs-fixer.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
name: PHP CS Fixer

on:
push:
branches:
- main
paths:
- '**/*.php'
pull_request:
paths:
- '**/*.php'

jobs:
php-cs-fixer:
name: PHP CS Fixer
runs-on: ubuntu-latest

steps:
- name: Checkout code
uses: actions/checkout@v3

- name: Set up PHP
uses: shivammathur/setup-php@v2
with:
php-version: 8.2
tools: composer

- name: Install dependencies
run: composer install --no-progress --prefer-dist

- name: Run PHP CS Fixer
run: vendor/bin/php-cs-fixer fix --dry-run --diff --allow-risky=yes
6 changes: 4 additions & 2 deletions .github/workflows/ci.yml → .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,9 @@ jobs:
- name: Install dependencies
run: composer install --no-progress --prefer-dist



- name: Run Tests without phpunit.xml
env:
NEO4J_ADDRESS: ${{ secrets.NEO4J_ADDRESS }}
NEO4J_USERNAME: ${{ secrets.NEO4J_USERNAME }}
NEO4J_PASSWORD: ${{ secrets.NEO4J_PASSWORD }}
run: vendor/bin/phpunit --configuration phpunit.dist.xml
9 changes: 9 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,5 +1,14 @@
#IDE
.idea/

#COMPOSER
vendor

#PHPUNIT
phpunit.xml
test
.phpunit.result.cache

#PHP-CS-FIXER
.php-cs-fixer.php
.php-cs-fixer.cache
16 changes: 16 additions & 0 deletions .php-cs-fixer.dist.php
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
<?php declare(strict_types=1);

use PhpCsFixer\Config;
use PhpCsFixer\Finder;

return (new Config())
->setRules([
'@PSR12' => true,
])
->setFinder(
Finder::create()
->in(__DIR__)
->exclude([
'vendor',
])
);
15 changes: 9 additions & 6 deletions composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -8,11 +8,9 @@
"ext-json": "*",
"php": "^8.1"
},

"require-dev": {
"phpunit/phpunit": "^10.0",
"vimeo/psalm": "^5.26",
"friendsofphp/php-cs-fixer": "^3.67"
"phpunit/phpunit": "^11.0",
"friendsofphp/php-cs-fixer": "^3.68"
},
"autoload": {
"psr-4": {
Expand All @@ -30,10 +28,15 @@
"email": "[email protected]"
}
],
"symfony/finder": "^7.2",
"config": {
"allow-plugins": {
"php-http/discovery": true
}
},

"scripts": {
"cs": "vendor/bin/php-cs-fixer fix --dry-run --diff --allow-risky=yes",
"cs:fix": "vendor/bin/php-cs-fixer fix --allow-risky=yes"
}
}

}
Loading
Loading