Feature: Digital Audio Product Builder Overview

  # This scenario can be implemented as a frontend component test.
  # Refactored -> cypress/e2e/workstation/productBuilderMigration/digitalAudioProductBuilderOverview.feature
  @refactor_old
  @ows_assets
  @ows_product_digital
  @ows_product
  @graphql_product
  @ows_promo_player
  @frontend_distribution
  @id_e5bdc4556a7d11236126f3d79b0658a350390f2787948f225a0d504938eddd20
  Scenario: Promo Player is Not Available Without Valid Tracks or Artwork
    Given an orchard employee label_7123 for workstation
    And I log in to workstation silently
    When I am on the digital product overview page for the project: 3697912, product: 2020312
    Then the Promo Player should not be available

  # QA-999996, failing test, locator issue
  # This scenario can be implemented as a frontend component test.
  # Refactored -> cypress/e2e/workstation/productBuilderMigration/digitalAudioProductBuilderOverview.feature
  @refactor_old
  @ows_assets
  @ows_product_digital
  @ows_product
  @graphql_product
  @ows_promo_player
  @frontend_distribution
  @id_2f26246a2ebddea004678b28706d17a55fffc85bb89681649b656d11ec236519
  Scenario: Promo Player is Available with Valid Tracks and Artwork
    Given an orchard employee label_7123 for workstation
    And I log in to workstation silently
    When I am on the digital product overview page for the project: 3848088, product: 2205277
    Then the Promo Player should be available

  # Refactored -> cypress/e2e/workstation/productBuilderMigration/digitalAudioProductBuilderOverview.feature
  @refactor_old
  @ows_assets
  @ows_product_digital
  @ows_product
  @graphql_product
  @ows_promo_player
  @frontend_distribution
  @id_06a75326fb97b363c9f706540c544f5727932e7f8bde2cf40cfab7aaf4a5fdf8
  Scenario: Enabling and Disabling the Promo Player
    Given an orchard employee label_7123 for workstation
    And I log in to workstation silently
    When I am on the digital product overview page for the project: 3848088, product: 2205277
    And the product does not have an associated Promo Player
    Then the Promo Player Builder Page shows the Promo Player is enabled
    And the linked Promo Player matches the page settings
    And the linked Promo Player is enabled
    When I disable the product's Promo Player
    Then the stored Promo Player is disabled
    And the Promo Player Builder Page shows no url

  @refactor_keep
  @ows_assets
  @ows_product_workflow
  @ows_product_digital
  @ows_product
  @graphql_product
  @ows_promo_player
  @frontend_distribution
  @id_8d875f8783185c37afb7a79f54910bb1962de66ca2ead778e0c61748e49648d3
  Scenario Outline: Creating a Promo Player with specific Expiration Mode
    Given an orchard employee label_7123 for workstation
    And I log in to workstation silently
    When I am on the digital product overview page for the project: 3848088, product: 2205277
    And the product does not have an associated Promo Player
    And I set the product's release date in the future
    And I go to the digital product Overview step
    Then the Promo Player Builder Page shows the Promo Player is enabled
    When I go to the digital product Overview step
    And I select the <expiration_mode> Expiration Mode
    And I go to the digital product Overview step
    Then the Promo Player Builder Page shows the Promo Player is enabled
    And the linked Promo Player matches the page settings
    And the linked Promo Player leads to a valid page
    When I set the product's release date in the past
    And I go to the digital product Overview step
    Then the stored Promo Player leads to <released_behaviour> page

    Examples:
      | expiration_mode | released_behaviour |
      | on_release      | an invalid         |
      | never           | a valid            |
