feiweihy commented on a change in pull request #6366:
URL: https://github.com/apache/shardingsphere/pull/6366#discussion_r456205856



##########
File path: 
shardingsphere-sql-parser/shardingsphere-sql-parser-binder/src/test/java/org/apache/shardingsphere/sql/parser/binder/metadata/table/SchemaMetaDataLoaderTest.java
##########
@@ -0,0 +1,107 @@
+package org.apache.shardingsphere.sql.parser.binder.metadata.table;
+
+import 
org.apache.shardingsphere.sql.parser.binder.metadata.schema.SchemaMetaDataLoader;
+import org.junit.Test;
+
+import javax.sql.DataSource;
+import java.io.PrintWriter;
+import java.sql.Connection;
+import java.sql.DriverManager;
+import java.sql.SQLException;
+import java.sql.SQLFeatureNotSupportedException;
+import java.util.LinkedList;
+import java.util.logging.Logger;
+
+public final class SchemaMetaDataLoaderTest {
+    private static int minIdleCount = 3;
+    private static int maxIdleCount = 10;
+    private static int currentIdleCount = 0;
+    private static final LinkedList<Connection> connectionsPool = new 
LinkedList<Connection>();
+
+    @Test
+    public void assertloadAllTableNamesForOracle() throws SQLException {
+        LiteDatasource dataSource = new LiteDatasource();
+        SchemaMetaDataLoader.load(dataSource,5,"Oracle");
+    }
+
+    class LiteDatasource implements DataSource{
+        private String url = "jdbc:oracle:thin:@192.168.1.1:1521/orcl";
+        private String user = "test";
+        private String password = "111111";
+        public LiteDatasource(){
+            try {
+                for (int i = 0; i < SchemaMetaDataLoaderTest.maxIdleCount; 
i++) {
+                    Class.forName("oracle.jdbc.OracleDriver");

Review comment:
       I used externl lib to run this file.
   Do you have another way to do?




----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
[email protected]


Reply via email to