Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Sign in / Register
Toggle navigation
S
spring-boot
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
DEMO
spring-boot
Commits
65025d8d
Commit
65025d8d
authored
Jan 10, 2017
by
Andy Wilkinson
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Enable Neo4J's open in view interceptor by default
Closes gh-7943
parent
9159c87b
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
5 additions
and
5 deletions
+5
-5
Neo4jDataAutoConfiguration.java
.../autoconfigure/data/neo4j/Neo4jDataAutoConfiguration.java
+1
-1
Neo4jDataAutoConfigurationTests.java
...configure/data/neo4j/Neo4jDataAutoConfigurationTests.java
+4
-4
No files found.
spring-boot-autoconfigure/src/main/java/org/springframework/boot/autoconfigure/data/neo4j/Neo4jDataAutoConfiguration.java
View file @
65025d8d
...
...
@@ -120,7 +120,7 @@ public class Neo4jDataAutoConfiguration {
@ConditionalOnClass
({
WebMvcConfigurerAdapter
.
class
,
OpenSessionInViewInterceptor
.
class
})
@ConditionalOnMissingBean
(
OpenSessionInViewInterceptor
.
class
)
@ConditionalOnProperty
(
prefix
=
"spring.data.neo4j"
,
name
=
"open-in-view"
,
havingValue
=
"true"
)
@ConditionalOnProperty
(
prefix
=
"spring.data.neo4j"
,
name
=
"open-in-view"
,
havingValue
=
"true"
,
matchIfMissing
=
true
)
protected
static
class
Neo4jWebConfiguration
{
@Configuration
...
...
spring-boot-autoconfigure/src/test/java/org/springframework/boot/autoconfigure/data/neo4j/Neo4jDataAutoConfigurationTests.java
View file @
65025d8d
...
...
@@ -78,7 +78,7 @@ public class Neo4jDataAutoConfigurationTests {
assertThat
(
this
.
context
.
getBeansOfType
(
Neo4jOperations
.
class
)).
hasSize
(
1
);
assertThat
(
this
.
context
.
getBeansOfType
(
Neo4jTransactionManager
.
class
)).
hasSize
(
1
);
assertThat
(
this
.
context
.
getBeansOfType
(
OpenSessionInViewInterceptor
.
class
))
.
isEmpty
(
);
.
hasSize
(
1
);
}
@Test
...
...
@@ -131,10 +131,10 @@ public class Neo4jDataAutoConfigurationTests {
}
@Test
public
void
openSessionInViewInterceptorCanBe
En
abled
()
{
load
(
null
,
"spring.data.neo4j.open-in-view
=tru
e"
);
public
void
openSessionInViewInterceptorCanBe
Dis
abled
()
{
load
(
null
,
"spring.data.neo4j.open-in-view
:fals
e"
);
assertThat
(
this
.
context
.
getBeansOfType
(
OpenSessionInViewInterceptor
.
class
))
.
hasSize
(
1
);
.
isEmpty
(
);
}
@Test
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment