|
|
|
@ -1,5 +1,5 @@
|
|
|
|
|
/*
|
|
|
|
|
* Copyright 2012-2020 the original author or authors.
|
|
|
|
|
* Copyright 2012-2023 the original author or authors.
|
|
|
|
|
*
|
|
|
|
|
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
|
|
|
* you may not use this file except in compliance with the License.
|
|
|
|
@ -20,7 +20,6 @@ import org.mockito.ArgumentMatchers;
|
|
|
|
|
import org.neo4j.driver.Driver;
|
|
|
|
|
import org.neo4j.driver.Session;
|
|
|
|
|
import org.neo4j.driver.SessionConfig;
|
|
|
|
|
import org.neo4j.driver.types.TypeSystem;
|
|
|
|
|
|
|
|
|
|
import org.springframework.context.annotation.Bean;
|
|
|
|
|
import org.springframework.context.annotation.Configuration;
|
|
|
|
@ -40,9 +39,7 @@ class MockedDriverConfiguration {
|
|
|
|
|
@Bean
|
|
|
|
|
Driver driver() {
|
|
|
|
|
Driver driver = mock(Driver.class);
|
|
|
|
|
TypeSystem typeSystem = mock(TypeSystem.class);
|
|
|
|
|
Session session = mock(Session.class);
|
|
|
|
|
given(driver.defaultTypeSystem()).willReturn(typeSystem);
|
|
|
|
|
given(driver.session(ArgumentMatchers.any(SessionConfig.class))).willReturn(session);
|
|
|
|
|
return driver;
|
|
|
|
|
}
|
|
|
|
|