X-Git-Url: https://git.arvados.org/arvados.git/blobdiff_plain/f3250432a47c835f4c594348b0d4904a247c3365..2e104941dbf1e4bf92e0632cadeb946be0595d67:/services/api/test/functional/arvados/v1/filters_test.rb diff --git a/services/api/test/functional/arvados/v1/filters_test.rb b/services/api/test/functional/arvados/v1/filters_test.rb index 2349993617..2b1b675323 100644 --- a/services/api/test/functional/arvados/v1/filters_test.rb +++ b/services/api/test/functional/arvados/v1/filters_test.rb @@ -32,7 +32,7 @@ class Arvados::V1::FiltersTest < ActionController::TestCase filters: [['uuid', '@@', 'abcdef']], } assert_response 422 - assert_match /not supported/, json_response['errors'].join(' ') + assert_match(/not supported/, json_response['errors'].join(' ')) end test 'difficult characters in full text search' do @@ -52,7 +52,7 @@ class Arvados::V1::FiltersTest < ActionController::TestCase filters: [['any', '@@', ['abc', 'def']]], } assert_response 422 - assert_match /not supported/, json_response['errors'].join(' ') + assert_match(/not supported/, json_response['errors'].join(' ')) end test 'api responses provide timestamps with nanoseconds' do @@ -65,13 +65,16 @@ class Arvados::V1::FiltersTest < ActionController::TestCase %w(created_at modified_at).each do |attr| # Pass fixtures with null timestamps. next if item[attr].nil? - assert_match /^\d{4}-\d\d-\d\dT\d\d:\d\d:\d\d.\d{9}Z$/, item[attr] + assert_match(/^\d{4}-\d\d-\d\dT\d\d:\d\d:\d\d.\d{9}Z$/, item[attr]) end end end %w(< > <= >= =).each do |operator| test "timestamp #{operator} filters work with nanosecond precision" do + # Python clients like Node Manager rely on this exact format. + # If you must change this format for some reason, make sure you + # coordinate the change with them. expect_match = !!operator.index('=') mine = act_as_user users(:active) do Collection.create!(manifest_text: '')