From 7254e5abdea16c8ea665eb5534153c7c6c6df104 Mon Sep 17 00:00:00 2001 From: gebele Date: Mon, 30 Mar 2015 16:31:26 +0200 Subject: use method for sort order --- test/aopweb.rb | 5 ++++- test/lazarweb.rb | 6 +++++- test/toxbank-investigation-biosearch.rb | 6 ++++-- test/toxbank-investigation-ftp.rb | 8 +++++--- test/toxbank-investigation-rest.rb | 6 ++++-- test/toxbank-investigation-sparql.rb | 8 ++++++-- test/toxbank-investigation-stress.rb | 4 +++- test/toxbank-investigation-workflow.rb | 6 +++++- 8 files changed, 36 insertions(+), 13 deletions(-) diff --git a/test/aopweb.rb b/test/aopweb.rb index 82156f9..2603206 100644 --- a/test/aopweb.rb +++ b/test/aopweb.rb @@ -22,7 +22,10 @@ Capybara.run_server = false Capybara.app_host = $aop[:uri] class LazarWebTest < MiniTest::Test - i_suck_and_my_tests_are_order_dependent! + + def self.test_order + :sorted + end include Capybara::DSL diff --git a/test/lazarweb.rb b/test/lazarweb.rb index 90e1292..c59eab4 100644 --- a/test/lazarweb.rb +++ b/test/lazarweb.rb @@ -21,7 +21,11 @@ rescue end class LazarWebTest < MiniTest::Test - i_suck_and_my_tests_are_order_dependent! + + def self.test_order + :sorted + end + include Capybara::DSL def test_00_xsetup diff --git a/test/toxbank-investigation-biosearch.rb b/test/toxbank-investigation-biosearch.rb index 30b1024..ea318ef 100644 --- a/test/toxbank-investigation-biosearch.rb +++ b/test/toxbank-investigation-biosearch.rb @@ -9,8 +9,10 @@ rescue end class TBInvestigationUploadBio < MiniTest::Test - i_suck_and_my_tests_are_order_dependent! - + + def self.test_order + :sorted + end # define different users $owner = $pi[:subjectid] diff --git a/test/toxbank-investigation-ftp.rb b/test/toxbank-investigation-ftp.rb index a311cc4..0f8290e 100644 --- a/test/toxbank-investigation-ftp.rb +++ b/test/toxbank-investigation-ftp.rb @@ -12,8 +12,10 @@ end class TBInvestigationFTP < MiniTest::Test - i_suck_and_my_tests_are_order_dependent! - + def self.test_order + :sorted + end + $testfile = File.join File.dirname(__FILE__), "data/toxbank-investigation/valid", "unformated.zip" $testdir = "nightlytempdir#{Time.now.strftime("%Y%m%d")}" # test directory on ftp server e.G.: nightlytempdir20140528 @@ -91,4 +93,4 @@ class TBInvestigationFTP < MiniTest::Test $ftp.close assert $ftp.closed?, "connection not closed" end -end \ No newline at end of file +end diff --git a/test/toxbank-investigation-rest.rb b/test/toxbank-investigation-rest.rb index 634934c..d14569b 100644 --- a/test/toxbank-investigation-rest.rb +++ b/test/toxbank-investigation-rest.rb @@ -9,7 +9,6 @@ rescue end class TBInvestigationBasic < MiniTest::Test - #i_suck_and_my_tests_are_order_dependent! # check response from service without header, # @note expect OpenTox::BadRequestError @@ -51,7 +50,10 @@ class TBInvestigationBasic < MiniTest::Test end class TBInvestigationREST < MiniTest::Test - i_suck_and_my_tests_are_order_dependent! + + def self.test_order + :sorted + end def test_00_pre_01_check_subjectids assert OpenTox::Authorization.is_token_valid(OpenTox::RestClientWrapper.subjectid), "Subjectid for default test user is not valid." diff --git a/test/toxbank-investigation-sparql.rb b/test/toxbank-investigation-sparql.rb index 8ca8a91..5bc3ddd 100644 --- a/test/toxbank-investigation-sparql.rb +++ b/test/toxbank-investigation-sparql.rb @@ -3,7 +3,9 @@ require_relative "toxbank-setup.rb" # Test API extension SPARQL templates class TBSPARQLTest < MiniTest::Test - i_suck_and_my_tests_are_order_dependent! + def self.test_order + :sorted + end # login as pi and create a test investigation def test_00_create_investigation @@ -219,7 +221,9 @@ end class TBSPARQLTestExtended < MiniTest::Test - i_suck_and_my_tests_are_order_dependent! + def self.test_order + :sorted + end # login as pi and create a test investigation def test_00_create_investigation diff --git a/test/toxbank-investigation-stress.rb b/test/toxbank-investigation-stress.rb index 9a0db72..6cd480c 100644 --- a/test/toxbank-investigation-stress.rb +++ b/test/toxbank-investigation-stress.rb @@ -10,7 +10,9 @@ end class StressTest < MiniTest::Test - i_suck_and_my_tests_are_order_dependent! + def self.test_order + :sorted + end # Do multiple POST and check if completed def test_01_multiple_upload diff --git a/test/toxbank-investigation-workflow.rb b/test/toxbank-investigation-workflow.rb index 6fb34b6..3215cb2 100644 --- a/test/toxbank-investigation-workflow.rb +++ b/test/toxbank-investigation-workflow.rb @@ -9,7 +9,11 @@ rescue end class TBInvestigationWorkflow < MiniTest::Test - i_suck_and_my_tests_are_order_dependent! + + def self.test_order + :sorted + end + # Permission Matrix for owner, user1 (with GET permission (e.G.: group-permission) and user2 (no permission) # Sum = isSummarySearchable=true # noSum = isSummarySearchable=false -- cgit v1.2.3