zabetak commented on code in PR #4791:
URL: https://github.com/apache/hive/pull/4791#discussion_r1366578877


##########
standalone-metastore/metastore-server/src/test/java/org/apache/hadoop/hive/metastore/tools/schematool/TestSchemaToolForMetastore.java:
##########
@@ -467,6 +471,18 @@ public void testMetastoreDbPropertiesAfterUpgrade() throws 
HiveMetaException, IO
     validateMetastoreDbPropertiesTable();
   }
 
+  @Test
+  public void testValidateHiveShortVersion() {
+    String hiveShortVersion = MetastoreVersionInfo.getShortVersion();
+    String hiveVersion = MetastoreVersionInfo.getVersion();
+    Assert.assertEquals(hiveVersion, StringUtils.join(hiveShortVersion, 
"-SNAPSHOT"));
+    Assert.assertTrue(hiveVersion.startsWith(hiveShortVersion));
+    String fileName = 
Stream.of("src/test/resources/sql/postgres/upgrade-3.1.3000-to-" , 
hiveShortVersion ,".postgres.sql").
+            collect(Collectors.joining());
+    File file = new File(fileName);
+    Assert.assertTrue(file.exists());

Review Comment:
   If there are no tests that are able to guarantee that the scripts exist and 
are working as expected then we should check how to improve code coverage. At 
the moment, I am not sure we are missing something. If we do then yes log a 
JIRA ticket and add your suggestions.
   
   The MariaDB failure is logged under 
https://issues.apache.org/jira/browse/HIVE-27749. Feel free to pick this up and 
fix it if you feel like it.



-- 
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.

To unsubscribe, e-mail: gitbox-unsubscr...@hive.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: gitbox-unsubscr...@hive.apache.org
For additional commands, e-mail: gitbox-h...@hive.apache.org

Reply via email to