@insights_regression
@insights_my_catalog
Feature: My Catalog Artists Tab

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

  @IN-12792
  @id_270ca5e0b6aa805b82ab4a81bff67f448a91fe833f71a7f240ccddc135373538
  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 Artists tab - My Catalog
    And I can verify table columns on the page: #|Artist|Country|Account|1dStreams|1dChange|7dStreams|7dChange|28dStreams|28dChange|All TimeStreams

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

  @IN-12810
  @id_ec058b0d7d2e87799f54ec272c652bb243e14bc5fbb81c43ebcd57536a4184da
  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 My Catalog - Artists tab
    And I click on 1dStreams column to sort asc My Catalog - Artists tab
    Then I can see list is correct on Artists tab no wait - My Catalog

    Then I click on 7dChange column to sort desc My Catalog - Artists tab
    And I click on 7dChange column to sort asc My Catalog - Artists tab
    Then I can see list is correct on Artists tab no wait - My Catalog

    Then I click on 28dChange column to sort desc My Catalog - Artists tab
    Then I can see list is correct on Artists tab no wait - My Catalog
    And I click on 28dChange column to sort asc My Catalog - Artists tab

    Then I click on All TimeStreams column to sort desc My Catalog - Artists tab
    And I click on All TimeStreams column to sort asc My Catalog - Artists tab
    Then I can see list is correct on Artists tab no wait - My Catalog

  @IN-12812
  @id_38bc03e7a3931427f99b466737d40eeda01d2a3d0663f0162962a85afcfe4925
  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_89a14b5a7cb8db2c120b365558b1d6e8303de49127741900d3030090a7a1fed7
  Scenario: [Regression][My Catalog][Artists] - customize popup
    Then I visit the insights /catalog/artists?offset=0&limit=2 page
    And I can see list of 2 is correct on Artists tab - My Catalog
    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_dfae66a2c9fbfdab5622996593c0d933ccb3fc8ab81d73ee2e95e7cd193f7c69
  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_1775de216f6507f5950f1809a4fadf234c88b02643b4671b31a58a80db9d2d22
  Scenario: [Regression][My Catalog][Products] - 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_d367d52e37aafedc44f364c824588fa29713081e0933e1c9802cbfd5a76accbd
  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
