From b5579543b5b3ed5200029fb60d9a30d1427a7240 Mon Sep 17 00:00:00 2001 From: Antonio Terceiro + Paulo Meirelles Date: Tue, 17 Jan 2012 20:10:50 +0300 Subject: [PATCH] also run plugins selenium tests --- lib/tasks/plugins_tests.rake | 13 ++++++++++++- plugins/mezuro/features/mezuro.feature | 15 +++++++++++++++ 2 files changed, 27 insertions(+), 1 deletion(-) diff --git a/lib/tasks/plugins_tests.rake b/lib/tasks/plugins_tests.rake index 576f412..b018713 100644 --- a/lib/tasks/plugins_tests.rake +++ b/lib/tasks/plugins_tests.rake @@ -82,9 +82,20 @@ namespace :test do end end + namespace :selenium do + task :enabled do + features = Dir.glob('config/plugins/*/features/*.feature') + if features.empty? + puts "No acceptance tests for enabled plugins, skipping" + else + sh 'xvfb-run', 'ruby', '-S', 'cucumber', '--profile', 'selenium', '--format', ENV['CUCUMBER_FORMAT'] || 'progress' , *features + end + end + end + end - task :noosfero_plugins => ['noosfero_plugins:available', 'noosfero_plugins:cucumber:enabled'] + task :noosfero_plugins => %w[ noosfero_plugins:available noosfero_plugins:cucumber:enabled noosfero_plugins:cucumber:enabled ] end diff --git a/plugins/mezuro/features/mezuro.feature b/plugins/mezuro/features/mezuro.feature index 1436501..f387e23 100644 --- a/plugins/mezuro/features/mezuro.feature +++ b/plugins/mezuro/features/mezuro.feature @@ -59,3 +59,18 @@ Feature: mezuro content And I press "Save" Then I should see "Qt-Calculator" +# @selenium +# Scenario: I delete a real mezuro content +# Given I am on My Community's cms +# And I follow "New content" +# And I follow "Kalibro project" +# And I fill in the following: +# | Title | Qt-Calculator | +# | License | GPL 2.0 | +# | Repository type | SUBVERSION | +# | Repository url | https://qt-calculator.svn.sourceforge.net/svnroot/qt-calculator | +# And I press "Save" +# And I follow "Qt-Calculator" +# And I follow "Destroy" +# And I press "Yes, I want." +# Then I should not see "Qt-Calculator" -- libgit2 0.21.2