@Test
  void testRemoveByTableName() {
    materializedViewsCache.putIfAbsent(defaultMV1, defaultMaterialization1);

    materializedViewsCache.remove(defaultMV1.getDbName(), defaultMV1.getTableName());

    assertThat(materializedViewsCache.get(defaultMV1.getDbName(), defaultMV1.getTableName()), is(nullValue()));
    assertThat(materializedViewsCache.get(defaultMaterialization1.getAst()).isEmpty(), is(true));
    assertThat(materializedViewsCache.isEmpty(), is(true));
    assertThat(materializedViewsCache.values().isEmpty(), is(true));
  }
Functional and parallel execution tests for {@link MaterializedViewsCache}.
Parallel execution test is disabled by default.
ql/src/test/org/apache/hadoop/hive/ql/metadata/TestMaterializedViewsCache.java