@Test
public void testSelectTracksSelectTrackWithSelectionFlag() throws Exception {

  Format audioFormat =
      buildAudioFormatWithLanguageAndFlags(
          "audio", /* language= */ null, /* selectionFlags= */ 0);
  Format formatWithSelectionFlag =
      buildAudioFormatWithLanguageAndFlags(
          "audio", /* language= */ null, C.SELECTION_FLAG_DEFAULT);
  TrackGroupArray trackGroups = wrapFormats(audioFormat, formatWithSelectionFlag);
  TrackSelectorResult result =
      trackSelector.selectTracks(
          new RendererCapabilities[] {ALL_AUDIO_FORMAT_SUPPORTED_RENDERER_CAPABILITIES},
          trackGroups,
          periodId,
          TIMELINE);
  assertFixedSelection(result.selections.get(0), trackGroups, formatWithSelectionFlag);
}