X-Git-Url: https://git.arvados.org/arvados.git/blobdiff_plain/0bd1c28bed9a0756c61037947d5a9dccd5066f00..040fdf6da00318b5b8e8e83eceeec783680ecb1c:/apps/workbench/test/integration/pipeline_templates_test.rb diff --git a/apps/workbench/test/integration/pipeline_templates_test.rb b/apps/workbench/test/integration/pipeline_templates_test.rb index d131986d25..19a51095de 100644 --- a/apps/workbench/test/integration/pipeline_templates_test.rb +++ b/apps/workbench/test/integration/pipeline_templates_test.rb @@ -2,7 +2,7 @@ require 'integration_helper' class PipelineTemplatesTest < ActionDispatch::IntegrationTest test "JSON popup available for strange components" do - Capybara.current_driver = Capybara.javascript_driver + need_javascript uuid = api_fixture("pipeline_templates")["components_is_jobspec"]["uuid"] visit page_with_token("active", "/pipeline_templates/#{uuid}") click_on "Components" @@ -12,4 +12,34 @@ class PipelineTemplatesTest < ActionDispatch::IntegrationTest assert(page.has_text?("script_parameters"), "components JSON not found") end + + test "pipeline template description" do + need_javascript + visit page_with_token("active", "/pipeline_templates") + + # go to Two Part pipeline template + within first('tr', text: 'Two Part Pipeline Template') do + find(".fa-gears").click + end + + # edit template description + within('.arv-description-as-subtitle') do + find('.fa-pencil').click + find('.editable-input textarea').set('*Textile description for pipeline template* - "Go to dashboard":/') + find('.editable-submit').click + end + wait_for_ajax + + # Verfiy edited description + assert page.has_no_text? '*Textile description for pipeline template*' + assert page.has_text? 'Textile description for pipeline template' + assert page.has_link? 'Go to dashboard' + click_link 'Go to dashboard' + assert page.has_text? 'Active pipelines' + + # again visit recent templates page and verify edited description + visit page_with_token("active", "/pipeline_templates") + assert page.has_no_text? '*Textile description for pipeline template*' + assert page.has_text? 'Textile description for pipeline template' + end end