module Workstation
  class ArtistPage < Workstation::BasePage
    page_url "/artistinfo/index/artist_id/<%=params[:artist_id]%>"

    div(:artist_form_wrap, id: "artistFormWrap")
    text_field(:artist_name, id: "artistName")
    select(:artist_country, id: "artistCountry")
    link(:submit, text: "Save General Information")

    def verify_artist_name_created(name)
      artist_form_wrap_element.element.wait_until(&:present?)
      expect(page_header).to include name
    end
  end
end
