@Override
  public void registerProvider(TableProvider provider) {
    if (providers.containsKey(provider.getTableType())) {
      throw new IllegalArgumentException(
          "Provider is already registered for table type: " + provider.getTableType());
    }

    initTablesFromProvider(provider);
    this.providers.put(provider.getTableType(), provider);
  }
@Test
  public void testRegisterProvider() throws Exception {
    store.registerProvider(new MockTableProvider("mock", "hello", "world"));
    assertNotNull(store.getProviders());
    assertEquals(2, store.getProviders().size());
    assertEquals("text", store.getProviders().get("text").getTableType());
    assertEquals("mock", store.getProviders().get("mock").getTableType());

    assertEquals(2, store.getTables().size());
  }