Skip to content

Commit

Permalink
fix ci
Browse files Browse the repository at this point in the history
  • Loading branch information
zhexuany committed Aug 22, 2019
1 parent f8c7bfe commit 85759b4
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 2 deletions.
4 changes: 3 additions & 1 deletion core/src/test/scala/org/apache/spark/sql/ViewTestSuite.scala
Original file line number Diff line number Diff line change
Expand Up @@ -20,5 +20,7 @@ class ViewTestSuite extends BaseTiSparkTest {

judge(s"select * from $table")
intercept[AnalysisException](spark.sql("select * from v"))

spark.sql("show tables").show(false)
}
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -86,7 +86,7 @@ public List<TiTableInfo> listTables(TiDBInfo db) {
tableMap = loadTables(db);
}
Collection<TiTableInfo> tables = tableMap.values();
return tables.stream().filter(TiTableInfo::isView).collect(Collectors.toList());
return tables.stream().filter(TiTableInfo::isNotView).collect(Collectors.toList());
}

public TiTableInfo getTable(TiDBInfo db, String tableName) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -94,6 +94,10 @@ public TiTableInfo(
primaryKeyColumn = primaryKey;
}

public boolean isNotView() {
return this.viewInfo == null;
}

public boolean isView() {
return this.viewInfo != null;
}
Expand Down

0 comments on commit 85759b4

Please sign in to comment.