Skip to content

Commit 2dd5732

Browse files
committed
[test] Add comment about left open resource as spring closes it
1 parent f9f6d3b commit 2dd5732

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

src/test/java/org/mybatis/spring/SqlSessionTemplateTest.java

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright 2010-2023 the original author or authors.
2+
* Copyright 2010-2024 the original author or authors.
33
*
44
* Licensed under the Apache License, Version 2.0 (the "License");
55
* you may not use this file except in compliance with the License.
@@ -94,6 +94,7 @@ void testRollback() {
9494

9595
@Test
9696
void testExecutorType() {
97+
// Do not close this, spring will close it
9798
SqlSessionTemplate template = new SqlSessionTemplate(sqlSessionFactory, ExecutorType.BATCH);
9899
assertThat(template.getExecutorType()).isEqualTo(ExecutorType.BATCH);
99100

0 commit comments

Comments
 (0)