-
Notifications
You must be signed in to change notification settings - Fork 65
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
build(deps): Bump neo4j.version from 5.16.0 to 5.17.0 (#933)
* build(deps): Bump neo4j.version from 5.16.0 to 5.17.0 Bumps `neo4j.version` from 5.16.0 to 5.17.0. Updates `org.neo4j:neo4j-cypher-javacc-parser` from 5.16.0 to 5.17.0 - [Release notes](https://github.com/neo4j/neo4j/releases) - [Commits](neo4j/neo4j@5.16.0...5.17.0) Updates `org.neo4j.test:neo4j-harness` from 5.16.0 to 5.17.0 - [Release notes](https://github.com/neo4j/neo4j/releases) - [Commits](neo4j/neo4j@5.16.0...5.17.0) --- updated-dependencies: - dependency-name: org.neo4j:neo4j-cypher-javacc-parser dependency-type: direct:production update-type: version-update:semver-minor - dependency-name: org.neo4j.test:neo4j-harness dependency-type: direct:development update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] <[email protected]> * Adapt to latest parser changes. * Polish. --------- Signed-off-by: dependabot[bot] <[email protected]> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: Michael Simons <[email protected]>
- Loading branch information
1 parent
0d981a8
commit 5309701
Showing
5 changed files
with
101 additions
and
4 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
29 changes: 29 additions & 0 deletions
29
neo4j-cypher-dsl-parser/src/main/java/org/neo4j/cypherdsl/parser/Statements.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
/* | ||
* Copyright (c) 2019-2024 "Neo4j," | ||
* Neo4j Sweden AB [https://neo4j.com] | ||
* | ||
* This file is part of Neo4j. | ||
* | ||
* Licensed under the Apache License, Version 2.0 (the "License"); | ||
* you may not use this file except in compliance with the License. | ||
* You may obtain a copy of the License at | ||
* | ||
* https://www.apache.org/licenses/LICENSE-2.0 | ||
* | ||
* Unless required by applicable law or agreed to in writing, software | ||
* distributed under the License is distributed on an "AS IS" BASIS, | ||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
* See the License for the specific language governing permissions and | ||
* limitations under the License. | ||
*/ | ||
package org.neo4j.cypherdsl.parser; | ||
|
||
import java.util.List; | ||
|
||
import org.neo4j.cypherdsl.core.Statement; | ||
|
||
record Statements(List<Statement> value) { | ||
Statements { | ||
value = value == null ? List.of() : List.copyOf(value); | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
45 changes: 45 additions & 0 deletions
45
neo4j-cypher-dsl-parser/src/test/java/org/neo4j/cypherdsl/parser/StatementsTest.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,45 @@ | ||
/* | ||
* Copyright (c) 2019-2024 "Neo4j," | ||
* Neo4j Sweden AB [https://neo4j.com] | ||
* | ||
* This file is part of Neo4j. | ||
* | ||
* Licensed under the Apache License, Version 2.0 (the "License"); | ||
* you may not use this file except in compliance with the License. | ||
* You may obtain a copy of the License at | ||
* | ||
* https://www.apache.org/licenses/LICENSE-2.0 | ||
* | ||
* Unless required by applicable law or agreed to in writing, software | ||
* distributed under the License is distributed on an "AS IS" BASIS, | ||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
* See the License for the specific language governing permissions and | ||
* limitations under the License. | ||
*/ | ||
package org.neo4j.cypherdsl.parser; | ||
|
||
import static org.assertj.core.api.Assertions.assertThat; | ||
|
||
import java.util.ArrayList; | ||
|
||
import org.junit.jupiter.api.Test; | ||
import org.neo4j.cypherdsl.core.Cypher; | ||
import org.neo4j.cypherdsl.core.Statement; | ||
|
||
class StatementsTest { | ||
|
||
@Test | ||
void shouldSupportNullIst() { | ||
var statements = new Statements(null); | ||
assertThat(statements.value()).isEmpty(); | ||
} | ||
|
||
@Test | ||
void shouldCopy() { | ||
var hlp = new ArrayList<Statement>(); | ||
hlp.add(Cypher.returning(Cypher.literalTrue()).build()); | ||
var statements = new Statements(hlp); | ||
hlp.clear(); | ||
assertThat(statements.value()).hasSize(1); | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters