diff options
author | gebele <gebele@in-silico.ch> | 2014-01-08 13:42:08 +0100 |
---|---|---|
committer | gebele <gebele@in-silico.ch> | 2014-01-08 13:42:08 +0100 |
commit | ad098c8ed566b0d974b9512cd8e52c575742a062 (patch) | |
tree | 7bc352155cdf11a9e0b9f0a96f5166f330c7101a | |
parent | b4ae6c5c91fb8dca26997c2adf61ce1e90e2e3fa (diff) |
check that authorized user can get ftp file
-rw-r--r-- | test/toxbank-investigation-rest.rb | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/test/toxbank-investigation-rest.rb b/test/toxbank-investigation-rest.rb index 5e356f4..971819d 100644 --- a/test/toxbank-investigation-rest.rb +++ b/test/toxbank-investigation-rest.rb @@ -480,8 +480,11 @@ class TBInvestigationREST < MiniTest::Test # @note data is available with policy def test_10_i_guest_can_get - res = OpenTox::RestClientWrapper.get @@uri.to_s, {}, {:accept => "application/rdf+xml"} + res = OpenTox::RestClientWrapper.get @@uri.to_s, {}, {:accept => "application/rdf+xml", :subjectid => $guestid} assert_match /<\?xml/, res + #guest is authorized to get ftp file + result = OpenTox::RestClientWrapper.get("#{@@uri}", {}, {:accept => "text/uri-list", :subjectid => $guestid}).split("\n") + assert_match "#{@@uri}/isatab/JIC37_Ethanol_0.07_Internal_1_3.txt", result.to_s end # get investigation/{id}/metadata in rdf and check content |