[Git][noosfero/noosfero][master] fix tests on CI environment

Leandro Nunes gitlab at mg.gitlab.com
Thu May 19 16:01:17 BRT 2016


Leandro Nunes pushed to branch master at Noosfero / noosfero


Commits:
100608aa by Leandro Nunes dos Santos at 2016-05-19T15:59:35-03:00
fix tests on CI environment

- - - - -


1 changed file:

- plugins/statistics/test/unit/statistics_block_test.rb


Changes:

=====================================
plugins/statistics/test/unit/statistics_block_test.rb
=====================================
--- a/plugins/statistics/test/unit/statistics_block_test.rb
+++ b/plugins/statistics/test/unit/statistics_block_test.rb
@@ -145,6 +145,7 @@ class StatisticsBlockTest < ActiveSupport::TestCase
 
     b = StatisticsBlock.new
     e = fast_create(Environment)
+    e.enable_plugin('ProductsPlugin')
 
     e1 = fast_create(Enterprise, :visible => true, :enabled => true, :environment_id => e.id)
     e2 = fast_create(Enterprise, :visible => true, :enabled => false, :environment_id => e.id)
@@ -168,6 +169,8 @@ class StatisticsBlockTest < ActiveSupport::TestCase
     b = StatisticsBlock.new
 
     e = fast_create(Enterprise)
+    environment = e.environment
+    environment.enable_plugin('ProductsPlugin')
 
     fast_create(Product, :profile_id => e.id)
     fast_create(Product, :profile_id => e.id)



View it on GitLab: https://gitlab.com/noosfero/noosfero/commit/100608aa7161a5beaf1124a91f77d4423e166ed1
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://listas.softwarelivre.org/pipermail/noosfero-dev/attachments/20160519/faae4067/attachment-0001.html>


More information about the Noosfero-dev mailing list