@insights_regression
@insights_my_catalog
@insights_my_catalog_artists
Feature: My Catalog Artists Tab

  Background: Account Page is opened in default state
    Given an orchard employee multiaccount1 for insights
    And I log in

  @IN-12792
  @id_5b85fadb84caf2bc7ea2cf13674ec3229456f84d561b43acfa7608ad24faf450
  Scenario: [Regression][My Catalog][Artists] - links and columns
    Then I visit the insights /catalog/artists?offset=0&limit=2 page
    And I can see My Catalog page with the artists table
    And I can verify links on My Catalog - Artists tab
    And I can verify table columns on the page: #|Artist|Account|1dStreams|1dChange|7dStreams|7dChange|28dStreams|28dChange|All TimeStreams

  @IN-12800
  @id_050c07e1fcee066419415c3774c7a469ea4bbd01b534c81bdd1cdea1867d3497
  Scenario: [Regression][My Catalog][Artists] - filters
    Then I visit the insights /catalog/artists?offset=0&limit=2 page
    When I can filter by Artist on My Catalog - Artists tab
    Then I can see list is correct on My Catalog - Artists tab
    When I can clear all Grid table filters on My Catalog - Artists tab
    Then I can see list is correct on My Catalog - Artists tab
    When I can filter by Label on My Catalog - Artists tab
    Then I can see list is correct on My Catalog - Artists tab
    When I can clear all Grid table filters on My Catalog - Artists tab
    Then I can see list is correct on My Catalog - Artists tab

  @IN-12810
  @id_eacff6c8d46aa3a785115cbb79d114abb4df949d9e12024ad33884352c311075
  Scenario: [Regression][My Catalog][Artists] - sortable column
    When I visit the insights /catalog/artists?offset=0&limit=2 page
    Then I click on 1dStreams column to sort desc on My Catalog - Artists tab
    And I click on 1dStreams column to sort asc on My Catalog - Artists tab
    Then I can see list is correct on My Catalog - Artists tab
    Then I click on 7dChange column to sort desc on My Catalog - Artists tab
    And I click on 7dChange column to sort asc on My Catalog - Artists tab
    Then I can see list is correct on My Catalog - Artists tab
    Then I click on 28dChange column to sort desc on My Catalog - Artists tab
    Then I can see list is correct on My Catalog - Artists tab
    And I click on 28dChange column to sort asc on My Catalog - Artists tab
    Then I click on All TimeStreams column to sort desc on My Catalog - Artists tab
    And I click on All TimeStreams column to sort asc on My Catalog - Artists tab
    Then I can see list is correct on My Catalog - Artists tab

  @IN-12812
  @id_947ad20095d7337aa4ecbcfe6e672bc737a7001ec2341dfe1cd6218fecab2de5
  Scenario Outline: [Regression][My Catalog][Artists] - <option> tooltip
    Then I visit the insights /catalog/artists?offset=0&limit=2 page
    And I can see tooltip for <option> on My Catalog - Artists tab

    Examples:
      | option  |
      | Account |
      | Artist  |
      | Flag    |

  @IN-12815
  @id_344c532f3d707ec67fb608e4986c0d51d081f97db08cf9cc5eb239f769bc8af0
  Scenario: [Regression][My Catalog][Artists] - customize popup
    Then I visit the insights /catalog/artists?offset=0&limit=2 page
    And I can see list is correct on My Catalog - Artists tab
    When I open Customize popup on a grid table
    And I can click on (1 Day) Streams column in Customize popup for grid
    Then I can close using cancel Customize popup on a grid table
    And I can see (1 Day) Streams column on a grid
    When I open Customize popup on a grid table
    And I can click on (1 Day) Streams column in Customize popup for grid
    Then I can close using save Customize popup on a grid table
    And I can't see (1 Day) Streams column on a grid
    When I open Customize popup on a grid table
    Then I can close using x-close Customize popup on a grid table

  @IN-12822
  @id_ecc374821cba7e3778e20d8d6b40f94197999180f548f48813d48c1b02da9199
  Scenario: [Regression][My Catalog][Artists] - artist data consistency
    Then I visit the insights /catalog/artists?offset=0&limit=2 page
    Then I can open artist page from Artists tab
    And I can verify data on Artist page is the same as on My Catalog - Artists tab

  @IN-12827
  @id_854d7801afa1d8ad09c746bc8c5755c07bc68408f4f1ee864c563c11fbc66021
  Scenario: [Regression][My Catalog][Artists] - artist row data
    When I visit the insights /catalog/artists?country=UY&country=PE&country=FK&country=EC&country=PY&offset=0&limit=2 page
    Then I can see table data is correct on My Catalog - Artists tab

  @IN-12833
  @id_be13e340a0f7b0d9a8a72220a2f4de2bc24baf62bc9c7ae83b08e1bf72bb9592
  Scenario: [Regression][My Catalog][Artists] - export
    Then I visit the insights /catalog/artists?offset=0&limit=2 page
    And I can verify exported data from My Catalog - Artists tab
