Skip to content

Commit

Permalink
Add test
Browse files Browse the repository at this point in the history
  • Loading branch information
adinauer committed Aug 14, 2023
1 parent d1c6d56 commit 50fc307
Showing 1 changed file with 7 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -92,6 +92,13 @@ class DatabaseUtilsTest {
assertEquals("/sqlite/db/some.db", details.dbName)
}

@Test
fun `detects db system for sqlite linux`() {
val details = DatabaseUtils.parse("jdbc:sqlite:/home/sqlite/db/some.db")
assertEquals("sqlite", details.dbSystem)
assertEquals("/home/sqlite/db/some.db", details.dbName)
}

@Test
fun `detects db system for mongo`() {
val details = DatabaseUtils.parse("jdbc:mongo://some-server.com:1234/mydb")
Expand Down

0 comments on commit 50fc307

Please sign in to comment.