@Test
  public void testCTASFollowedByTruncate() throws IOException {
    testTables.createTable(shell, "source", HiveIcebergStorageHandlerTestUtils.CUSTOMER_SCHEMA, fileFormat,
        HiveIcebergStorageHandlerTestUtils.CUSTOMER_RECORDS);

    shell.executeStatement(String.format(
        "CREATE EXTERNAL TABLE target STORED BY ICEBERG STORED AS %s %s AS SELECT * FROM source",
        fileFormat, testTables.locationForCreateTableSQL(TableIdentifier.of("default", "target"))));

    List<Object[]> objects = shell.executeStatement("SELECT * FROM target ORDER BY customer_id");
    HiveIcebergTestUtils.validateData(HiveIcebergStorageHandlerTestUtils.CUSTOMER_RECORDS,
        HiveIcebergTestUtils.valueForRow(HiveIcebergStorageHandlerTestUtils.CUSTOMER_SCHEMA, objects), 0);

    shell.executeStatement("TRUNCATE TABLE target");

    objects = shell.executeStatement("SELECT * FROM target");
    Assert.assertTrue(objects.isEmpty());
  }
Creates Iceberg tables using CTAS, and runs select queries against these new tables to verify table content.
iceberg/iceberg-handler/src/test/java/org/apache/iceberg/mr/hive/TestHiveIcebergCTAS.java