@insights_regression
@insights_song
@insights_song_playlists
Feature: Song Playlists Tab Sorting By Column - 2

  @IN-13264
  @id_5ac609e7878c074beb3f0e131d4adc7c4a85ecd40e203c1362d230313cdff968
  Scenario Outline: [Song> Playlists tab] Sorting verification. - <column> column
    Given a user from single_label for insights
    And I log in
    When I visit the insights /song/QM6MZ2214888/playlists?offset=0&playlistAppearances=<appearances>&limit=10 page
    And I can apply all columns on playlists on Song page
    And I click on <column> column title on Playlists tab
    Then I can verify "orderBy":"<orderByColumn>" in @soundRecordingPlaylistPlacements request
    And I can verify "orderDir":"<sort1>" in @soundRecordingPlaylistPlacements request
    And I can verify data playlists on Song page
    And I click on <column> column title on Playlists tab
    Then I can verify "orderBy":"<orderByColumn>" in @soundRecordingPlaylistPlacements request
    And I can verify "orderDir":"<sort2>" in @soundRecordingPlaylistPlacements request
    And I can verify data playlists on Song page

    Examples:
      | appearances | column            | sort1 | sort2 | orderByColumn                       |
      | past        | Last Added        | desc  | asc   | last_added_on_date                  |
      | current     | First Play        | desc  | asc   | first_play                          |
      | past        | Date Removed      | desc  | asc   | removed_on                          |
      | current     | Genre             | asc   | desc  | playlist_genres                     |
      | past        | 28dEntity Streams | desc  | asc   | total_playlist_streams_last_28_days |
      | current     | 7dCompletion Rate | desc  | asc   | completion_rate_last_7_days         |
