File tree Expand file tree Collapse file tree 1 file changed +30
-0
lines changed
src/test/java/org/javawebstack/orm/test Expand file tree Collapse file tree 1 file changed +30
-0
lines changed Original file line number Diff line number Diff line change 1+ package org .javawebstack .orm .test ;
2+
3+ import static org .junit .jupiter .api .Assertions .*;
4+
5+ import org .javawebstack .orm .wrapper .SQLDriverFactory ;
6+ import org .javawebstack .orm .wrapper .SQLDriverNotFoundException ;
7+ import org .junit .jupiter .api .Test ;
8+
9+ import java .util .HashMap ;
10+
11+ class SQLDriverFactoryTest {
12+ private SQLDriverFactory factory = new SQLDriverFactory (new HashMap <String , String >() {{
13+ put ("file" , "sb.sqlite" );
14+ put ("host" , "localhost" );
15+ put ("port" , "3306" );
16+ put ("name" , "app" );
17+ put ("user" , "root" );
18+ put ("password" , "" );
19+ }});
20+
21+ @ Test
22+ public void testSQLite () throws SQLDriverNotFoundException {
23+ assertNotNull (factory .getDriver ("sqlite" ));
24+ }
25+
26+ @ Test
27+ public void testMySQL () throws SQLDriverNotFoundException {
28+ assertNotNull (factory .getDriver ("mysql" ));
29+ }
30+ }
You can’t perform that action at this time.
0 commit comments