### Question:
FileConfigSource extends AbstractConfigSource implements WatchableSource<Path>, ParsableSource, PollableSource<byte[]> { @Override public Optional<String> mediaType() { return super.mediaType(); } FileConfigSource(Builder builder); static FileConfigSource create(Config metaConfig); static Builder builder(); @Override boolean isModified(byte[] stamp); @Override Path target(); @Override Optional<ConfigParser.Content> load(); @Override Optional<ConfigParser> parser(); @Override Optional<String> mediaType(); @Override Optional<PollingStrategy> pollingStrategy(); @Override Optional<ChangeWatcher<Object>> changeWatcher(); @Override boolean exists();  }### Answer:
@Test public void testGetMediaTypeSet() { FileConfigSource configSource = ConfigSources.file("application.conf") .optional() .mediaType(TEST_MEDIA_TYPE) .build(); assertThat(configSource.mediaType(), is(Optional.of(TEST_MEDIA_TYPE))); }
@Test public void testGetMediaTypeUnknown() { FileConfigSource configSource = ConfigSources.file("application.unknown") .optional() .build(); assertThat(configSource.mediaType(), is(Optional.empty())); }
@Test public void testBuilderWithMediaType() { ConfigSource configSource = ConfigSources.file("application.conf") .mediaType("application/hocon") .build(); assertThat(configSource, notNullValue()); }