Skip to content

Commit

Permalink
FIX: row.getData()
Browse files Browse the repository at this point in the history
  • Loading branch information
Coho04 committed Nov 19, 2023
1 parent dcdaa8e commit 93d1800
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 7 deletions.
4 changes: 2 additions & 2 deletions pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -62,8 +62,8 @@
<artifactId>maven-compiler-plugin</artifactId>
<version>3.11.0</version>
<configuration>
<source>${java.version}</source>
<target>${java.version}</target>
<source>17</source>
<target>17</target>
</configuration>
</plugin>
<plugin>
Expand Down
12 changes: 7 additions & 5 deletions src/test/java/de/goldendeveloper/mysql/MYSQLTest.java
Original file line number Diff line number Diff line change
@@ -1,9 +1,11 @@
package de.goldendeveloper.mysql;

import de.goldendeveloper.mysql.exceptions.NoConnectionException;
import org.junit.jupiter.api.Test;

import java.io.FileInputStream;
import java.io.IOException;
import java.sql.SQLException;
import java.util.Properties;

import static org.junit.jupiter.api.Assertions.*;
Expand Down Expand Up @@ -71,7 +73,7 @@ void getUsers() {
}

@Test
void existsDatabase() {
void existsDatabase() throws NoConnectionException, SQLException {
if (!setupTest().existsDatabase("test_mysql_api"))
setupTest().createDatabase("test_mysql_api");
assertTrue(setupTest().existsDatabase("test_mysql_api"));
Expand All @@ -88,14 +90,14 @@ void customExecute() {
}

@Test
void getDatabase() {
void getDatabase() throws NoConnectionException, SQLException {
if (!setupTest().existsDatabase("test_mysql_api"))
setupTest().createDatabase("test_mysql_api");
assertNotNull(setupTest().getDatabase("test_mysql_api"));
}

@Test
void createDatabase() {
void createDatabase() throws NoConnectionException, SQLException {
if (!setupTest().existsDatabase("test_mysql_api"))
setupTest().createDatabase("test_mysql_api");
assertTrue(setupTest().existsDatabase("test_mysql_api"));
Expand All @@ -107,7 +109,7 @@ void onFlushPrivileges() {
}

@Test
void switchDatabase() {
void switchDatabase() throws NoConnectionException, SQLException {
MYSQL mysql = setupTest();
if (!mysql.existsDatabase("test_mysql_api"))
mysql.createDatabase("test_mysql_api");
Expand All @@ -123,7 +125,7 @@ void createUser() {
}

@Test
void getDatabases() {
void getDatabases() throws NoConnectionException, SQLException {
MYSQL mysql = setupTest();
if (!mysql.existsDatabase("test_mysql_api"))
mysql.createDatabase("test_mysql_api");
Expand Down

0 comments on commit 93d1800

Please sign in to comment.