Feature: Digital Audio Product Builder

  @ows_product_workflow
  @ows_product_digital
  @ows_product
  @frontend_distribution
  Scenario: Digital audio product created via landing page with required fields
    Given a standalone Workstation label_7123 user
    And I am on the Project::ProjectDetailsPage for a newly created project
    When I add a product to the project
    And I select digital audio as the product type
    And I populate the digital product 2 landing page form with required data
    And I use an orchard-generated UPC
    And I submit the digital audio product landing page form
    Then I see the correct basics data on the digital product overview page

  @ows_product_workflow
  @ows_product_digital
  @ows_product
  @frontend_distribution
  Scenario: Digital audio 2 product created via landing page with all fields
    Given a standalone Workstation label_7123 user
    And I am on the Project::ProjectDetailsPage for a newly created project
    When I add a product to the project
    And I select digital audio as the product type
    And I populate the digital product 2 landing page form with all data
    And I use my own UPC
    And I submit the digital audio product landing page form
    Then I see the correct basics data on the digital product overview page
    And I see the UPC on the digital product overview page
  
  @frontend_distribution
  Scenario: Digital audio 2 product validation on landing page
    Given a standalone Workstation label_7123 user
    And I have an existing empty project
    And I am on the Project::ProjectDetailsPage for the project
    When I add a product to the project
    And I select digital audio as the product type
    And I submit the empty digital audio product landing page form
    Then I should see a validation error message on the product form
    And I should get 3 validation messages for the required fields

  @ows_product_workflow
  @ows_product_digital
  @ows_product
  @ows_territories
  @ows_carveouts
  @frontend_distribution
  @ows_contracts
  Scenario: Add and delete territory carveouts from digital product in ALW
    Given a standalone Workstation label_7123 user
    And I have an existing digital product on QA
    And I am on the Project::DigitalProductOverviewPage for the product
    When I go to the digital product territories section
    And I move all territories to cleared for sale
    And I move the continent Europe to NOT cleared for sale
    And I move the European country Austria to cleared for sale
    Then I see 63 territories NOT cleared for sale on the territory restrictions page
    When I save the digital product territories
    Then I am on the product publishing page
    And I go to the digital product overview step
    Then I see 64 territories NOT cleared for sale on the digital product overview page

  @ows_product_workflow
  @ows_product_digital
  @ows_product
  @frontend_distribution
  @ows_contracts
  # DIG-5577
  Scenario: Submit Digital Product
    Given a standalone Workstation label_7123 user
    And I have a digital product I wish to submit
    And my product is in-progress
    When I am on the Project::DigitalProductOverviewPage for the product
    And I submit my product
    Then I should see the submit success modal
    And my product should be in SUBMITTED status

  @ows_product_workflow
  @ows_product_digital
  @ows_product
  @frontend_distribution
  Scenario: Unsubmit Digital Product
    Given a standalone Workstation label_7123 user
    And I have a digital product I wish to unsubmit
    When I am on the Project::DigitalProductOverviewPage for the product
    And I unsubmit my product
    Then my product should be in IN PROGRESS status

  @ows_product_workflow
  @ows_product_digital
  @ows_product
  @frontend_distribution
  @regression
  Scenario: Create digital product as subaccount
    Given a standalone Workstation subaccount_1 user
    When I am on the Project::ProjectDetailsPage for a newly created project
    And I add a product to the project
    And I select digital audio as the product type
    And I populate the digital product 2 landing page form with required data
    And I use an orchard-generated UPC
    And I submit the digital audio product landing page form
    Then my product should be in IN PROGRESS status
