Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
path: root/spec
diff options
context:
space:
mode:
authorDmitriy Zaporozhets <dzaporozhets@gitlab.com>2014-12-05 13:19:10 +0300
committerDmitriy Zaporozhets <dzaporozhets@gitlab.com>2014-12-05 13:19:10 +0300
commite6c5a8b161c89a03ca5ee6666f65cf4cfbfa4ab9 (patch)
treea038e35744c8adaa8d01eb3b623a2e8f7efcb50d /spec
parent9ce9814ee3281be0e7cfa4653480284e4fe3eb9f (diff)
parentcdc62cffcb86dfd939c119cba2acaf266af39f23 (diff)
Merge branch 'rake_task_for_google_email_schema_verfication' into 'master'
Rake task for google email schema verfication #1607 See merge request !1300
Diffstat (limited to 'spec')
-rw-r--r--spec/tasks/gitlab/mail_google_schema_whitelisting.rb27
1 files changed, 27 insertions, 0 deletions
diff --git a/spec/tasks/gitlab/mail_google_schema_whitelisting.rb b/spec/tasks/gitlab/mail_google_schema_whitelisting.rb
new file mode 100644
index 00000000000..45aaf0fc90b
--- /dev/null
+++ b/spec/tasks/gitlab/mail_google_schema_whitelisting.rb
@@ -0,0 +1,27 @@
+require 'spec_helper'
+require 'rake'
+
+describe 'gitlab:mail_google_schema_whitelisting rake task' do
+ before :all do
+ Rake.application.rake_require "tasks/gitlab/task_helpers"
+ Rake.application.rake_require "tasks/gitlab/mail_google_schema_whitelisting"
+ # empty task as env is already loaded
+ Rake::Task.define_task :environment
+ end
+
+ describe 'call' do
+ before do
+ # avoid writing task output to spec progress
+ $stdout.stub :write
+ end
+
+ let :run_rake_task do
+ Rake::Task["gitlab:mail_google_schema_whitelisting"].reenable
+ Rake.application.invoke_task "gitlab:mail_google_schema_whitelisting"
+ end
+
+ it 'should run the task without errors' do
+ expect { run_rake_task }.to_not raise_error
+ end
+ end
+end