Skip to content

Commit

Permalink
Add Neo4jVersion.513 and use it
Browse files Browse the repository at this point in the history
  • Loading branch information
Mats-SX committed Oct 23, 2023
1 parent ccade71 commit a556791
Show file tree
Hide file tree
Showing 7 changed files with 22 additions and 49 deletions.

This file was deleted.

Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ public final class Neo4jProxyFactoryImpl implements Neo4jProxyFactory {

@Override
public boolean canLoad(Neo4jVersion version) {
return version == Neo4jVersion.V_Dev;
return version == Neo4jVersion.V_5_13;
}

@Override
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -119,7 +119,7 @@ public class InMemoryStorageEngineFactory implements StorageEngineFactory {
static final String IN_MEMORY_STORAGE_ENGINE_NAME = "in-memory-513";

public InMemoryStorageEngineFactory() {
StorageEngineProxyApi.requireNeo4jVersion(Neo4jVersion.V_Dev, StorageEngineFactory.class);
StorageEngineProxyApi.requireNeo4jVersion(Neo4jVersion.V_5_13, StorageEngineFactory.class);
}

@Override
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ public class StorageEngineProxyFactoryImpl implements StorageEngineProxyFactory

@Override
public boolean canLoad(Neo4jVersion version) {
return version == Neo4jVersion.V_Dev;
return version == Neo4jVersion.V_5_13;
}

@Override
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -40,9 +40,10 @@ public enum Neo4jVersion {
V_5_10,
V_5_11,
V_5_12,
V_5_13,
V_Dev;

private static final int MINOR_DEV_VERSION = 10;
private static final int MINOR_DEV_VERSION = 14;

@Override
public String toString() {
Expand All @@ -63,6 +64,8 @@ public String toString() {
return "5.11";
case V_5_12:
return "5.12";
case V_5_13:
return "5.13";
case V_Dev:
return "dev";
default:
Expand Down Expand Up @@ -150,6 +153,8 @@ static Neo4jVersion parse(String version) {
return Neo4jVersion.V_5_11;
case 12:
return Neo4jVersion.V_5_12;
case 13:
return Neo4jVersion.V_5_13;
default:
if (minorVersion >= MINOR_DEV_VERSION) {
return Neo4jVersion.V_Dev;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,8 @@ class Neo4jVersionTest {
"5.10.0, V_5_10",
"5.11.0, V_5_11",
"5.12.0, V_5_12",
"5.13.0, V_Dev",
"5.13.0, V_5_13",
"5.14.0, V_Dev",
})
void testParse(String input, Neo4jVersion expected) {
assertEquals(expected.name(), Neo4jVersion.parse(input).name());
Expand Down
11 changes: 11 additions & 0 deletions proc/sysinfo/src/test/java/org/neo4j/gds/SysInfoProcTest.java
Original file line number Diff line number Diff line change
Expand Up @@ -78,6 +78,9 @@ class SysInfoProcTest extends BaseProcTest {
"Neo4j 5.12",
"Neo4j 5.12 (placeholder)",

"Neo4j 5.13",
"Neo4j 5.13 (placeholder)",

"Neo4j DEV",
"Neo4j DEV (placeholder)",

Expand Down Expand Up @@ -190,6 +193,14 @@ void testSysInfoProc() throws IOException {
"Neo4j 5.12"
);
break;
case V_5_13:
expectedCompatibilities = Set.of(
"Neo4j Settings 5.x (placeholder)",
"Neo4j Settings 5.x",
"Neo4j 5.13 (placeholder)",
"Neo4j 5.13"
);
break;
case V_Dev:
expectedCompatibilities = Set.of(
"Neo4j Settings 5.x",
Expand Down

0 comments on commit a556791

Please sign in to comment.