Skip to content

Commit c63fad9

Browse files
committed
Merge remote-tracking branch 'origin/main' into response-parser-1963796193
2 parents 39f4458 + da0472d commit c63fad9

22 files changed

+1561
-1349
lines changed

.env

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
# Database Configuration
2+
NEO4J_ADDRESS=https://6f72daa1.databases.neo4j.io/
3+
NEO4J_USERNAME=neo4j
4+
NEO4J_PASSWORD=O9lWmptqBgxBOz8NVcTJjgs3cHPyYmsy63ui6Spmw1d0

.github/workflows/cs-fixer.yml

Lines changed: 32 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,32 @@
1+
name: PHP CS Fixer
2+
3+
on:
4+
push:
5+
branches:
6+
- main
7+
paths:
8+
- '**/*.php'
9+
pull_request:
10+
paths:
11+
- '**/*.php'
12+
13+
jobs:
14+
php-cs-fixer:
15+
name: PHP CS Fixer
16+
runs-on: ubuntu-latest
17+
18+
steps:
19+
- name: Checkout code
20+
uses: actions/checkout@v3
21+
22+
- name: Set up PHP
23+
uses: shivammathur/setup-php@v2
24+
with:
25+
php-version: 8.2
26+
tools: composer
27+
28+
- name: Install dependencies
29+
run: composer install --no-progress --prefer-dist
30+
31+
- name: Run PHP CS Fixer
32+
run: vendor/bin/php-cs-fixer fix --dry-run --diff --allow-risky=yes

.github/workflows/ci.yml renamed to .github/workflows/test.yml

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,9 @@ jobs:
3535
- name: Install dependencies
3636
run: composer install --no-progress --prefer-dist
3737

38-
39-
4038
- name: Run Tests without phpunit.xml
39+
env:
40+
NEO4J_ADDRESS: ${{ secrets.NEO4J_ADDRESS }}
41+
NEO4J_USERNAME: ${{ secrets.NEO4J_USERNAME }}
42+
NEO4J_PASSWORD: ${{ secrets.NEO4J_PASSWORD }}
4143
run: vendor/bin/phpunit --configuration phpunit.dist.xml

.gitignore

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,14 @@
1+
#IDE
12
.idea/
3+
4+
#COMPOSER
25
vendor
6+
7+
#PHPUNIT
38
phpunit.xml
49
test
510
.phpunit.result.cache
11+
12+
#PHP-CS-FIXER
13+
.php-cs-fixer.php
14+
.php-cs-fixer.cache

.php-cs-fixer.cache

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
{"php":"8.3.6","version":"3.68.0:v3.68.0#73f78d8b2b34a0dd65fedb434a602ee4c2c8ad4c","indent":" ","lineEnding":"\n","rules":{"binary_operator_spaces":{"default":"at_least_single_space"},"blank_line_after_opening_tag":true,"blank_line_between_import_groups":true,"blank_lines_before_namespace":true,"braces_position":{"allow_single_line_empty_anonymous_classes":true},"class_definition":{"inline_constructor_arguments":false,"space_before_parenthesis":true},"compact_nullable_type_declaration":true,"declare_equal_normalize":true,"lowercase_cast":true,"lowercase_static_reference":true,"new_with_parentheses":true,"no_blank_lines_after_class_opening":true,"no_extra_blank_lines":{"tokens":["use"]},"no_leading_import_slash":true,"no_whitespace_in_blank_line":true,"ordered_class_elements":{"order":["use_trait"]},"ordered_imports":{"imports_order":["class","function","const"],"sort_algorithm":"none"},"return_type_declaration":true,"short_scalar_cast":true,"single_import_per_statement":{"group_to_single_imports":false},"single_space_around_construct":{"constructs_followed_by_a_single_space":["abstract","as","case","catch","class","const_import","do","else","elseif","final","finally","for","foreach","function","function_import","if","insteadof","interface","namespace","new","private","protected","public","static","switch","trait","try","use","use_lambda","while"],"constructs_preceded_by_a_single_space":["as","else","elseif","use_lambda"]},"single_trait_insert_per_statement":true,"ternary_operator_spaces":true,"unary_operator_spaces":{"only_dec_inc":true},"visibility_required":true,"blank_line_after_namespace":true,"constant_case":true,"control_structure_braces":true,"control_structure_continuation_position":true,"elseif":true,"function_declaration":true,"indentation_type":true,"line_ending":true,"lowercase_keywords":true,"method_argument_space":{"attribute_placement":"ignore","on_multiline":"ensure_fully_multiline"},"no_break_comment":true,"no_closing_tag":true,"no_multiple_statements_per_line":true,"no_space_around_double_colon":true,"no_spaces_after_function_name":true,"no_trailing_whitespace":true,"no_trailing_whitespace_in_comment":true,"single_blank_line_at_eof":true,"single_class_element_per_statement":{"elements":["property"]},"single_line_after_imports":true,"spaces_inside_parentheses":true,"statement_indentation":true,"switch_case_semicolon_to_colon":true,"switch_case_space":true,"encoding":true,"full_opening_tag":true,"strict_param":true},"hashes":{"tests\/Unit\/Neo4jExceptionUnitTest.php":"0d7842780eeb9729d501831ee55df0d8","tests\/Unit\/ResultRowTest.php":"f5ee9f21d2439793a290e8ab946a7f32","tests\/Unit\/Neo4jQueryAPIUnitTest.php":"54be7f7b0f9dcf13d62c4912127583b9","tests\/Integration\/Neo4jQueryAPIIntegrationTest.php":"44977ffd6c09c505b00c8ef4857b8bfd","tests\/Integration\/Neo4jOGMTest.php":"73136b2d28fbb4fa298467d1ab3e18c8","src\/OGM.php":"93aae9c7afc8dbfd5aa00bc1d264ad19","src\/Results\/ResultRow.php":"ad55ec1bd999a8f6ad6b18874c4017b5","src\/Results\/ResultSet.php":"5f7748a356bf0fb30403e3c5a411bd24","src\/Exception\/Neo4jException.php":"dfb0f6933b9d3913c5495ba6d801d5f1","src\/Objects\/Path.php":"88c95962a6316ba7aa2fa3f0f6e31627","src\/Objects\/Node.php":"4a8ab7b8bd1981ee4d35d8c52b81c7c3","src\/Objects\/ProfiledQueryPlanArguments.php":"1be7b230a034a72c13349a5670a34a2f","src\/Objects\/Person.php":"f2f469937660f5454761e4f31154e081","src\/Objects\/Point.php":"169715b2157e08482e420374e6ca4cc3","src\/Objects\/Bookmarks.php":"50f89ca88b2df817433ce8237ccc0f18","src\/Objects\/ResultCounters.php":"a9372c98fe7bede10cb004af30ea502f","src\/Objects\/Relationship.php":"f6347c0260780d4f5d2dc407dc97e25e","src\/Transaction.php":"e456922858b31d87b17ca47d25d58474","tests\/resources\/expected\/complex-query-profile.php":"cc2b1e7e731c30a8855d9fa368cd55f3","src\/Neo4jQueryAPI.php":"8bffb787a834b58523e89fc9e5c19fe3","src\/Objects\/ProfiledQueryPlan.php":"d9ba608f3177426ea34d73276d75f20b"}}

.php-cs-fixer.dist.php

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
<?php declare(strict_types=1);
2+
3+
use PhpCsFixer\Config;
4+
use PhpCsFixer\Finder;
5+
6+
return (new Config())
7+
->setRules([
8+
'@PSR12' => true,
9+
])
10+
->setFinder(
11+
Finder::create()
12+
->in(__DIR__)
13+
->exclude([
14+
'vendor',
15+
])
16+
);

.php-cs-fixer.php

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
<?php declare(strict_types=1);
2+
3+
use PhpCsFixer\Config;
4+
use PhpCsFixer\Finder;
5+
6+
return (new Config())
7+
->setRiskyAllowed(true) // Allow risky fixers
8+
->setRules([
9+
'@PSR12' => true,
10+
'strict_param' => true, // This is a risky rule
11+
])
12+
->setFinder(
13+
Finder::create()
14+
->in(__DIR__)
15+
->exclude([
16+
'vendor',
17+
])
18+
);

composer.json

Lines changed: 9 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -8,11 +8,9 @@
88
"ext-json": "*",
99
"php": "^8.1"
1010
},
11-
1211
"require-dev": {
13-
"phpunit/phpunit": "^10.0",
14-
"vimeo/psalm": "^5.26",
15-
"friendsofphp/php-cs-fixer": "^3.67"
12+
"phpunit/phpunit": "^11.0",
13+
"friendsofphp/php-cs-fixer": "^3.68"
1614
},
1715
"autoload": {
1816
"psr-4": {
@@ -30,10 +28,15 @@
3028
"email": "[email protected]"
3129
}
3230
],
33-
"symfony/finder": "^7.2",
3431
"config": {
3532
"allow-plugins": {
3633
"php-http/discovery": true
3734
}
35+
},
36+
37+
"scripts": {
38+
"cs": "vendor/bin/php-cs-fixer fix --dry-run --diff --allow-risky=yes",
39+
"cs:fix": "vendor/bin/php-cs-fixer fix --allow-risky=yes"
3840
}
39-
}
41+
42+
}

0 commit comments

Comments
 (0)