Skip to content

Commit

Permalink
fix: re-adds test utility method for connection (#1178)
Browse files Browse the repository at this point in the history
Re-adds test utility method, which had its signature changed. Marks the re-added method as deprecated and delegates execution to the new one. This should prevent compilation errors for the projects that are using it.
  • Loading branch information
thiagotnunes committed May 16, 2021
1 parent 6b11a46 commit 0e0dcb7
Showing 1 changed file with 21 additions and 0 deletions.
Expand Up @@ -220,6 +220,27 @@ public void verifyStatementsInFile(String filename, Class<?> resourceClass, bool
verifyStatementsInFile(null, filename, resourceClass, allowParallel);
}

/**
* Reads sql statements from the specified file name and executes and verifies these. Statements
* that are preceded by an @EXPECT statement are verified against the @EXPECT specification.
* Statements without an @EXPECT statement will be executed and its result will be ignored, unless
* the statement throws an exception, which will fail the test case.
*
* <p>The {@link com.google.cloud.spanner.jdbc.Connection}s that the statements are executed on
* must be created by a {@link GenericConnectionProvider}
*
* @param filename The file name containing the statements. Statements must be separated by a
* semicolon (;)
* @param resourceClass The class that should be used to locate the resource specified by the file
* name
* @deprecated use {@link AbstractSqlScriptVerifier#verifyStatementsInFile(String, Class,
* boolean)} instead. This method does not allow parallel batch execution.
*/
@Deprecated
public void verifyStatementsInFile(String filename, Class<?> resourceClass) throws Exception {
this.verifyStatementsInFile(filename, resourceClass, false);
}

/**
* Reads sql statements from the specified file name and executes and verifies these. Statements
* that are preceded by an @EXPECT statement are verified against the @EXPECT specification.
Expand Down

0 comments on commit 0e0dcb7

Please sign in to comment.