[ARVADOS] updated: 1.3.0-623-gdf5f366f4
Git user
git at public.curoverse.com
Thu Mar 28 21:06:52 UTC 2019
Summary of changes:
build/package-build-dockerfiles/debian8/Dockerfile | 2 +
build/package-test-dockerfiles/debian8/Dockerfile | 2 +
build/run-library.sh | 11 +-
build/run-tests.sh | 650 +++++++++++++--------
lib/cloud/azure/azure.go | 7 +-
lib/controller/cmd.go | 2 +-
lib/controller/handler_test.go | 2 +-
lib/controller/proxy.go | 1 +
lib/dispatchcloud/cmd.go | 14 +-
lib/dispatchcloud/container/queue.go | 39 +-
lib/dispatchcloud/dispatcher.go | 34 +-
lib/dispatchcloud/dispatcher_test.go | 49 +-
lib/dispatchcloud/driver.go | 32 +-
lib/dispatchcloud/scheduler/interfaces.go | 2 +-
lib/dispatchcloud/scheduler/run_queue_test.go | 2 +-
lib/dispatchcloud/scheduler/sync.go | 10 +-
lib/dispatchcloud/test/queue.go | 13 +-
lib/dispatchcloud/test/stub_driver.go | 102 ++--
lib/dispatchcloud/worker/pool.go | 83 ++-
lib/dispatchcloud/worker/runner.go | 154 +++++
lib/dispatchcloud/worker/worker.go | 235 +++++---
lib/dispatchcloud/worker/worker_test.go | 9 +-
lib/service/cmd.go | 32 +-
lib/service/cmd_test.go | 78 +++
lib/service/error.go | 38 ++
sdk/go/arvados/client.go | 15 +
sdk/go/arvados/config.go | 53 ++
sdk/go/keepclient/discover.go | 8 +-
services/api/Gemfile | 6 +-
services/api/Gemfile.lock | 12 +-
services/api/app/models/arvados_model.rb | 15 +-
services/api/app/models/collection.rb | 12 +-
services/api/app/models/container.rb | 4 +-
services/api/app/models/container_request.rb | 5 +-
services/api/app/models/group.rb | 3 +-
services/api/app/models/link.rb | 5 +-
services/api/app/models/node.rb | 12 +-
services/api/lib/enable_jobs_api.rb | 4 +-
services/api/test/fixtures/collections.yml | 62 ++
services/api/test/fixtures/containers.yml | 2 +
services/api/test/fixtures/nodes.yml | 5 +
services/api/test/performance/links_index_test.rb | 8 +-
services/api/test/unit/arvados_model_test.rb | 1 +
services/api/test/unit/container_test.rb | 2 +
services/api/test/unit/crunch_dispatch_test.rb | 11 -
services/api/test/unit/job_test.rb | 5 +-
services/crunch-run/background.go | 13 +-
services/crunch-run/crunchrun.go | 9 +-
services/crunch-run/crunchrun_test.go | 2 +-
services/fuse/arvados_fuse/__init__.py | 62 ++
services/fuse/arvados_fuse/crunchstat.py | 99 ++--
services/fuse/setup.py | 3 +-
tools/arvbox/lib/arvbox/docker/service/nginx/run | 127 +++-
.../lib/arvbox/docker/service/nginx/run-service | 119 ----
.../crunchstat_summary/command.py | 30 +-
.../crunchstat_summary/dygraphs.py | 4 +-
.../crunchstat_summary/reader.py | 10 +-
.../crunchstat_summary/summarizer.py | 66 ++-
.../crunchstat_summary/webchart.py | 10 +-
...4-dz642-lymtndkpy39eibk-arv-mount.txt.gz.report | 4 +-
...-dz642-lymtndkpy39eibk-crunchstat.txt.gz.report | 3 +-
...ainer_9tee4-dz642-lymtndkpy39eibk.txt.gz.report | 3 +-
.../tests/logfile_20151204190335.txt.gz.report | 3 +-
.../tests/logfile_20151210063411.txt.gz.report | 3 +-
.../tests/logfile_20151210063439.txt.gz.report | 3 +-
tools/crunchstat-summary/tests/test_examples.py | 36 +-
66 files changed, 1721 insertions(+), 741 deletions(-)
create mode 100644 lib/dispatchcloud/worker/runner.go
create mode 100644 lib/service/cmd_test.go
create mode 100644 lib/service/error.go
mode change 120000 => 100755 tools/arvbox/lib/arvbox/docker/service/nginx/run
delete mode 100755 tools/arvbox/lib/arvbox/docker/service/nginx/run-service
via df5f366f4bd87ee90cf39248542435b1b924b58a (commit)
via cb4efac6793d18892dde09c631895cb98c3df470 (commit)
via 5950f9090f499c770908622bd300d98f9f1da1fc (commit)
via efe2b4796783672eb3385b45dfcd4b83055cbfa3 (commit)
via 5fed82405ed48bb67d73273eb32b5fd3b764e6dc (commit)
via 004cf8a6b59ac10bf84e213309289e6138c48b7d (commit)
via e281a42ac126952960838e0aae826e00091a8404 (commit)
via 433d10b31924631f5b4c18b828301a4fe45bbf0c (commit)
via ae283129a01be7e7ce1faf83cde20370c06a571f (commit)
via e4b51619430c53f6da603dc8f9b5ece1cb33449f (commit)
via 4d9a5c4f0f19c2e6d394dca6a1de903dc09c43e5 (commit)
via 115cbd6482632c47fdcbbbe4abc9543e7e8e30ec (commit)
via 7ef48a5956f4032eee9790b06cc18ab36395d788 (commit)
via 998d661e82eb093e2e64965b342081e3c86e0831 (commit)
via b715e06b9f8ac2ca1037a63dc90b3c235557dbde (commit)
via d23f9c8a99742f116983ce644f25d7ddacfbee4e (commit)
via d98030aacf47c9b0ce815c40e4bfcc0252f86898 (commit)
via 4dd55960919ee83018711a7f475db9ba205a698f (commit)
via 701d59fcd4d183528d5c54e64c6237e5daa2b419 (commit)
via 7f93b99e31c946a1a92dafcbcd1d0e36a710c32b (commit)
via 6fa0df704b8b1e52579307d64c2e6d4edfa9aff7 (commit)
via 762b54b8933db923bd02e34fd22e4ee93fa06827 (commit)
via 00592ebe08406f1b7649f758d4ed25a2882672ef (commit)
via 040c1afc709ae32d5cedd2f0a3815a12b1909bf3 (commit)
via 32b86ab3e24cbc47344a23be2587af1bc73bf165 (commit)
via d0dc4cc1dcf3ae3aaf4b76b0147cc81a58fa7c59 (commit)
via 1e6ed4a630296305042938975a5680db13980165 (commit)
via 0b2a6fedb1a3e03a7c8173331f8ebcca1ca4a125 (commit)
via d2aa25400fe0b6b8fc231b1c5e0d32085e38b6bc (commit)
via 215d15bc03a38be1965a5d9df21417a3f7eae032 (commit)
via fb8c51a195f2d9603cb129d8c3a21dc5d700aab3 (commit)
via a07891c7ac7e90ebdf35ae1812ec03c818fe2a67 (commit)
via 743680ab176697218aa41839149e02a160786bdf (commit)
via b0efcaab2225121f27aa18f5cb19cc5ce8f5beb7 (commit)
via 0e1e46da333f606b8b3293367641818fd3cc9ff4 (commit)
via a614135cd8e4c2e03593a8f16210a30fdef5d90b (commit)
via ef288ca2cdefe06e736972d06d5ffb177b0cac51 (commit)
via 1c21d98f48d42c453fb8ac2f9869d0240a437d1d (commit)
via dbbc5a9078c0fe88160729f3ca8f56673397b106 (commit)
via 51b136d8f7937b7f16aa8457a6b97c9b0e63d388 (commit)
via aed47afc7647f24af6541ff03a0cc0649a5358ee (commit)
via c9baf35106d64d8b26741256c145616bfbea9645 (commit)
via 2e1e5442ae846a026c5de7edb0dd78e09c56b5a7 (commit)
via e6f350e56674e3f19d24755b94a22e59cf8478b6 (commit)
via 0e0cbc43912e4bd8ad3fda616e552380d61c3f8d (commit)
via b286e013ab8ccc64d06ee107c155a03696fddeed (commit)
via 41365ac598721e31fc88c462934e0a06cafe2aae (commit)
via daa4ee15fdf51a573f96b74c9fd01747b63bbeb0 (commit)
via 3384d541acca51c346f8ebfe08b0dc93a33936ff (commit)
via 19ab7c19fcd56b05ff2d06f7fb4b66a515c90f4b (commit)
via 96f73954851d44ab715fa0b34861a93c00aa0519 (commit)
via c04d16f1482d10d64ddcceba4dcc7ab06032f033 (commit)
via cd020c016106fbe844501c5f434c16f4def4e08d (commit)
via 8d660b2b276475f1bd5b56614a28a33a358dd038 (commit)
via d924d8bf8b08a009e6fe2c75cf97b8d27ebb6089 (commit)
via 0be3e2c040d8d785bbd5c3e8d9de62c0fbaee0ec (commit)
via 97432e0e9d32a41c48a5298a0dbfd70b310e20e7 (commit)
via 5b863886118890cc81b728a3a606ea823c836f2b (commit)
via 395b0e17c81d2b8767a240193ab94363cbc0dae8 (commit)
via 20a7cf92c668d8d75ca3d1d64f028973a71245d4 (commit)
from 728522fbc034711e87954bcbdcfa4a3bf7c470e3 (commit)
Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.
commit df5f366f4bd87ee90cf39248542435b1b924b58a
Author: Lucas Di Pentima <ldipentima at veritasgenetics.com>
Date: Thu Mar 28 18:06:37 2019 -0300
14873: Fixes unit tests.
JSONB columns shouldn't be declared as 'serialized' because their content
get encoded twice.
When not declaring them as serialized, their default values (eg: [], {})
should be explicitly set.
Fixes on fixtures when default JSONB values are not defined on the schema.
Arvados-DCO-1.1-Signed-off-by: Lucas Di Pentima <ldipentima at veritasgenetics.com>
diff --git a/services/api/Gemfile b/services/api/Gemfile
index 76b121de6..6d4295694 100644
--- a/services/api/Gemfile
+++ b/services/api/Gemfile
@@ -10,7 +10,11 @@ gem 'responders', '~> 2.0'
group :test, :development do
gem 'factory_bot_rails'
gem 'database_cleaner'
- gem 'ruby-prof'
+
+ # As of now (2019-03-27) There's an open issue about incompatibilities with
+ # newer versions of this gem: https://github.com/rails/rails-perftest/issues/38
+ gem 'ruby-prof', '~> 0.15.0'
+
# Note: "require: false" here tells bunder not to automatically
# 'require' the packages during application startup. Installation is
# still mandatory.
diff --git a/services/api/Gemfile.lock b/services/api/Gemfile.lock
index 63ea79be8..f4e094ee9 100644
--- a/services/api/Gemfile.lock
+++ b/services/api/Gemfile.lock
@@ -163,7 +163,7 @@ GEM
net-ssh-gateway (2.0.0)
net-ssh (>= 4.0.0)
nio4r (2.3.1)
- nokogiri (1.10.1)
+ nokogiri (1.10.2)
mini_portile2 (~> 2.4.0)
oauth2 (1.4.1)
faraday (>= 0.8, < 0.16.0)
@@ -184,7 +184,7 @@ GEM
rack
rake (>= 0.8.1)
pg (1.1.4)
- power_assert (1.1.3)
+ power_assert (1.1.4)
public_suffix (3.0.3)
rack (2.0.6)
rack-test (0.6.3)
@@ -227,7 +227,7 @@ GEM
actionpack (>= 4.2.0, < 6.0)
railties (>= 4.2.0, < 6.0)
retriable (1.4.1)
- ruby-prof (0.17.0)
+ ruby-prof (0.15.9)
rvm-capistrano (1.5.6)
capistrano (~> 2.15.4)
safe_yaml (1.0.5)
@@ -250,7 +250,7 @@ GEM
activesupport (>= 4.0)
sprockets (>= 3.0.0)
sshkey (2.0.0)
- test-unit (3.3.0)
+ test-unit (3.3.1)
power_assert
therubyracer (0.12.3)
libv8 (~> 3.16.14.15)
@@ -296,7 +296,7 @@ DEPENDENCIES
rails-observers
rails-perftest
responders (~> 2.0)
- ruby-prof
+ ruby-prof (~> 0.15.0)
rvm-capistrano
safe_yaml
simplecov (~> 0.7.1)
@@ -308,4 +308,4 @@ DEPENDENCIES
uglifier (~> 2.0)
BUNDLED WITH
- 1.17.3
+ 1.16.6
diff --git a/services/api/app/models/arvados_model.rb b/services/api/app/models/arvados_model.rb
index ffcf09172..e619abe8c 100644
--- a/services/api/app/models/arvados_model.rb
+++ b/services/api/app/models/arvados_model.rb
@@ -117,6 +117,15 @@ class ArvadosModel < ApplicationRecord
raise ArgumentError.new("#{colname} parameter cannot have non-string hash keys")
end
end
+ # Check JSONB columns that aren't listed on serialized_attributes
+ columns.select{|c| c.type == :jsonb}.collect{|j| j.name}.each do |colname|
+ if serialized_attributes.include? colname || raw_params[colname.to_sym].nil?
+ next
+ end
+ if has_nonstring_keys?(raw_params[colname.to_sym])
+ raise ArgumentError.new("#{colname} parameter cannot have non-string hash keys")
+ end
+ end
end
ActionController::Parameters.new(raw_params).permit!
end
@@ -413,7 +422,8 @@ class ArvadosModel < ApplicationRecord
def self.full_text_tsvector
parts = full_text_searchable_columns.collect do |column|
- cast = serialized_attributes[column] ? '::text' : ''
+ is_jsonb = self.columns.select{|x|x.name == column}[0].type == :jsonb
+ cast = (is_jsonb || serialized_attributes[column]) ? '::text' : ''
"coalesce(#{column}#{cast},'')"
end
"to_tsvector('english', substr(#{parts.join(" || ' ' || ")}, 0, 8000))"
@@ -674,7 +684,8 @@ class ArvadosModel < ApplicationRecord
# we'll convert symbols to strings when loading from the
# database. (Otherwise, loading and saving an object with existing
# symbols in a serialized field will crash.)
- self.class.serialized_attributes.each do |colname, attr|
+ jsonb_cols = self.class.columns.select{|c| c.type == :jsonb}.collect{|j| j.name}
+ (jsonb_cols + self.class.serialized_attributes.keys).uniq.each do |colname|
if self.class.has_symbols? attributes[colname]
attributes[colname] = self.class.recursive_stringify attributes[colname]
send(colname + '=',
diff --git a/services/api/app/models/collection.rb b/services/api/app/models/collection.rb
index 136e0ed26..cb23df1c2 100644
--- a/services/api/app/models/collection.rb
+++ b/services/api/app/models/collection.rb
@@ -14,10 +14,10 @@ class Collection < ArvadosModel
include CommonApiTemplate
include Trashable
- serialize :properties, Hash
- serialize :storage_classes_desired, Array
- serialize :storage_classes_confirmed, Array
+ # Posgresql JSONB columns should NOT be declared as serialized, Rails 5
+ # already know how to properly treat them.
+ before_validation :fill_field_defaults
before_validation :default_empty_manifest
before_validation :default_storage_classes, on: :create
before_validation :check_encoding
@@ -653,4 +653,10 @@ class Collection < ArvadosModel
self.current_version_uuid ||= self.uuid
true
end
+
+ def fill_field_defaults
+ self.properties ||= {}
+ self.storage_classes_desired ||= []
+ self.storage_classes_confirmed ||= []
+ end
end
diff --git a/services/api/app/models/container.rb b/services/api/app/models/container.rb
index abcfdbd29..b02989457 100644
--- a/services/api/app/models/container.rb
+++ b/services/api/app/models/container.rb
@@ -17,13 +17,13 @@ class Container < ArvadosModel
extend DbCurrentTime
extend LogReuseInfo
+ # Posgresql JSONB columns should NOT be declared as serialized, Rails 5
+ # already know how to properly treat them.
serialize :environment, Hash
serialize :mounts, Hash
serialize :runtime_constraints, Hash
serialize :command, Array
serialize :scheduling_parameters, Hash
- serialize :secret_mounts, Hash
- serialize :runtime_status, Hash
before_validation :fill_field_defaults, :if => :new_record?
before_validation :set_timestamps
diff --git a/services/api/app/models/container_request.rb b/services/api/app/models/container_request.rb
index 921d4bee6..80e1bf3ff 100644
--- a/services/api/app/models/container_request.rb
+++ b/services/api/app/models/container_request.rb
@@ -19,13 +19,13 @@ class ContainerRequest < ArvadosModel
primary_key: :uuid,
}
- serialize :properties, Hash
+ # Posgresql JSONB columns should NOT be declared as serialized, Rails 5
+ # already know how to properly treat them.
serialize :environment, Hash
serialize :mounts, Hash
serialize :runtime_constraints, Hash
serialize :command, Array
serialize :scheduling_parameters, Hash
- serialize :secret_mounts, Hash
before_validation :fill_field_defaults, :if => :new_record?
before_validation :validate_runtime_constraints
@@ -191,6 +191,7 @@ class ContainerRequest < ArvadosModel
self.environment ||= {}
self.runtime_constraints ||= {}
self.mounts ||= {}
+ self.secret_mounts ||= {}
self.cwd ||= "."
self.container_count_max ||= Rails.configuration.container_count_max
self.scheduling_parameters ||= {}
diff --git a/services/api/app/models/group.rb b/services/api/app/models/group.rb
index 46bb447d1..b63d0ae2a 100644
--- a/services/api/app/models/group.rb
+++ b/services/api/app/models/group.rb
@@ -12,7 +12,8 @@ class Group < ArvadosModel
include CanBeAnOwner
include Trashable
- serialize :properties, Hash
+ # Posgresql JSONB columns should NOT be declared as serialized, Rails 5
+ # already know how to properly treat them.
after_create :invalidate_permissions_cache
after_update :maybe_invalidate_permissions_cache
diff --git a/services/api/app/models/link.rb b/services/api/app/models/link.rb
index ac3efe310..a95feb83c 100644
--- a/services/api/app/models/link.rb
+++ b/services/api/app/models/link.rb
@@ -6,7 +6,10 @@ class Link < ArvadosModel
include HasUuid
include KindAndEtag
include CommonApiTemplate
- serialize :properties, Hash
+
+ # Posgresql JSONB columns should NOT be declared as serialized, Rails 5
+ # already know how to properly treat them.
+
before_create :permission_to_attach_to_objects
before_update :permission_to_attach_to_objects
after_update :maybe_invalidate_permissions_cache
diff --git a/services/api/app/models/node.rb b/services/api/app/models/node.rb
index 3d8b91b4b..ecafcdd21 100644
--- a/services/api/app/models/node.rb
+++ b/services/api/app/models/node.rb
@@ -8,8 +8,11 @@ class Node < ArvadosModel
include HasUuid
include KindAndEtag
include CommonApiTemplate
- serialize :info, Hash
- serialize :properties, Hash
+
+ # Posgresql JSONB columns should NOT be declared as serialized, Rails 5
+ # already know how to properly treat them.
+
+ before_validation :fill_field_defaults
before_validation :ensure_ping_secret
after_update :dns_server_update
@@ -138,6 +141,11 @@ class Node < ArvadosModel
protected
+ def fill_field_defaults
+ self.info ||= {}
+ self.properties ||= {}
+ end
+
def assign_hostname
if self.hostname.nil? and Rails.configuration.assign_node_hostname
self.hostname = self.class.hostname_for_slot(self.slot_number)
diff --git a/services/api/lib/enable_jobs_api.rb b/services/api/lib/enable_jobs_api.rb
index d99edd801..63543ab3a 100644
--- a/services/api/lib/enable_jobs_api.rb
+++ b/services/api/lib/enable_jobs_api.rb
@@ -33,7 +33,7 @@ Disable_jobs_api_method_list = ["jobs.create",
def check_enable_legacy_jobs_api
if Rails.configuration.enable_legacy_jobs_api == false ||
(Rails.configuration.enable_legacy_jobs_api == "auto" &&
- ActiveRecord::Base.connection.exec_query("select count(*) from jobs").first["count"] == "0")
- Rails.configuration.disable_api_methods = Disable_jobs_api_method_list
+ Job.count == 0)
+ Rails.configuration.disable_api_methods += Disable_jobs_api_method_list
end
end
diff --git a/services/api/test/fixtures/collections.yml b/services/api/test/fixtures/collections.yml
index 8763f3944..f539eea58 100644
--- a/services/api/test/fixtures/collections.yml
+++ b/services/api/test/fixtures/collections.yml
@@ -14,6 +14,7 @@ user_agreement:
updated_at: 2013-12-26T19:22:54Z
manifest_text: ". 6a4ff0499484c6c79c95cd8c566bd25f+249025 0:249025:GNU_General_Public_License,_version_3.pdf\n"
name: user_agreement
+ properties: {}
collection_owned_by_active:
uuid: zzzzz-4zz18-bv31uwvy3neko21
@@ -28,6 +29,7 @@ collection_owned_by_active:
manifest_text: ". 37b51d194a7513e45b56f6524f2d51f2+3 0:3:bar\n"
name: owned_by_active
version: 2
+ properties: {}
collection_owned_by_active_past_version_1:
uuid: zzzzz-4zz18-znfnqtbbv4spast
@@ -42,6 +44,7 @@ collection_owned_by_active_past_version_1:
manifest_text: ". 37b51d194a7513e45b56f6524f2d51f2+3 0:3:bar\n"
name: owned_by_active_version_1
version: 1
+ properties: {}
foo_file:
uuid: zzzzz-4zz18-znfnqtbbv4spc3w
@@ -55,6 +58,7 @@ foo_file:
updated_at: 2015-02-03T17:22:54Z
manifest_text: ". acbd18db4cc2f85cedef654fccc4a4d8+3 0:3:foo\n"
name: foo_file
+ properties: {}
bar_file:
uuid: zzzzz-4zz18-ehbhgtheo8909or
@@ -68,6 +72,7 @@ bar_file:
updated_at: 2015-02-03T17:22:54Z
manifest_text: ". 37b51d194a7513e45b56f6524f2d51f2+3 0:3:bar\n"
name: bar_file
+ properties: {}
baz_file:
uuid: zzzzz-4zz18-y9vne9npefyxh8g
@@ -81,6 +86,7 @@ baz_file:
updated_at: 2014-02-03T17:22:54Z
manifest_text: ". 73feffa4b7f6bb68e44cf984c85f6e88+3 0:3:baz\n"
name: baz_file
+ properties: {}
w_a_z_file:
uuid: zzzzz-4zz18-25k12570yk134b3
@@ -95,6 +101,7 @@ w_a_z_file:
manifest_text: ". 4c6c2c0ac8aa0696edd7316a3be5ca3c+5 0:5:w\\040\\141\\040z\n"
name: "\"w a z\" file"
version: 2
+ properties: {}
w_a_z_file_version_1:
uuid: zzzzz-4zz18-25k12570yk1ver1
@@ -109,6 +116,7 @@ w_a_z_file_version_1:
manifest_text: ". 4d20280d5e516a0109768d49ab0f3318+3 0:3:waz\n"
name: "waz file"
version: 1
+ properties: {}
multilevel_collection_1:
uuid: zzzzz-4zz18-pyw8yp9g3pr7irn
@@ -122,6 +130,7 @@ multilevel_collection_1:
updated_at: 2014-02-03T17:22:54Z
manifest_text: ". d41d8cd98f00b204e9800998ecf8427e+0 0:0:file1 0:0:file2 0:0:file3\n./dir1 d41d8cd98f00b204e9800998ecf8427e+0 0:0:file1 0:0:file2 0:0:file3\n./dir1/subdir d41d8cd98f00b204e9800998ecf8427e+0 0:0:file1 0:0:file2 0:0:file3\n./dir2 d41d8cd98f00b204e9800998ecf8427e+0 0:0:file1 0:0:file2 0:0:file3\n"
name: multilevel_collection_1
+ properties: {}
multilevel_collection_2:
uuid: zzzzz-4zz18-45xf9hw1sxkhl6q
@@ -136,6 +145,7 @@ multilevel_collection_2:
updated_at: 2014-02-03T17:22:54Z
manifest_text: "./dir1/sub1 d41d8cd98f00b204e9800998ecf8427e+0 0:0:a 0:0:b\n./dir2/sub2 d41d8cd98f00b204e9800998ecf8427e+0 0:0:c 0:0:d\n"
name: multilevel_collection_2
+ properties: {}
docker_image:
uuid: zzzzz-4zz18-1v45jub259sjjgb
@@ -150,6 +160,7 @@ docker_image:
updated_at: 2014-06-11T17:22:54Z
manifest_text: ". d21353cfe035e3e384563ee55eadbb2f+67108864 5c77a43e329b9838cbec18ff42790e57+55605760 0:122714624:d8309758b8fe2c81034ffc8a10c36460b77db7bc5e7b448c4e5b684f9d95a678.tar\n"
name: docker_image
+ properties: {}
# tagged docker image with sha256:{hash}.tar filename
docker_image_1_12:
@@ -164,6 +175,7 @@ docker_image_1_12:
updated_at: 2016-10-19 08:50:45.652930000 Z
manifest_text: ". d21353cfe035e3e384563ee55eadbb2f+67108864 5c77a43e329b9838cbec18ff42790e57+55605760 0:122714624:sha256:d8309758b8fe2c81034ffc8a10c36460b77db7bc5e7b448c4e5b684f9d95a678.tar\n"
name: docker_image_1_12
+ properties: {}
unlinked_docker_image:
uuid: zzzzz-4zz18-d0d8z5wofvfgwad
@@ -179,6 +191,7 @@ unlinked_docker_image:
updated_at: 2014-06-11T17:22:54Z
manifest_text: ". fca529cfe035e3e384563ee55eadbb2f+67108863 0:67108863:bcd02158b8fe2c81034ffc8a10c36460b77db7bc5e7b448c4e5b684f9d95a678.tar\n"
name: unlinked_docker_image
+ properties: {}
empty:
uuid: zzzzz-4zz18-gs9ooj1h9sd5mde
@@ -193,6 +206,7 @@ empty:
updated_at: 2014-06-11T17:22:54Z
manifest_text: ""
name: empty_collection
+ properties: {}
foo_collection_in_aproject:
uuid: zzzzz-4zz18-fy296fx3hot09f7
@@ -204,6 +218,7 @@ foo_collection_in_aproject:
updated_at: 2014-04-21 15:37:48 -0400
manifest_text: ". acbd18db4cc2f85cedef654fccc4a4d8+3 0:3:foo\n"
name: "zzzzz-4zz18-fy296fx3hot09f7 added sometime"
+ properties: {}
user_agreement_in_anonymously_accessible_project:
uuid: zzzzz-4zz18-uukreo9rbgwsujr
@@ -215,6 +230,7 @@ user_agreement_in_anonymously_accessible_project:
updated_at: 2014-06-13 20:42:26 -0800
manifest_text: ". 6a4ff0499484c6c79c95cd8c566bd25f+249025 0:249025:GNU_General_Public_License,_version_3.pdf\n"
name: GNU General Public License, version 3
+ properties: {}
public_text_file:
uuid: zzzzz-4zz18-4en62shvi99lxd4
@@ -226,6 +242,7 @@ public_text_file:
updated_at: 2015-02-12 16:58:03 -0500
manifest_text: ". f0ef7081e1539ac00ef5b761b4fb01b3+12 0:12:Hello\\040world.txt\n"
name: Hello world
+ properties: {}
baz_collection_name_in_asubproject:
uuid: zzzzz-4zz18-lsitwcf548ui4oe
@@ -237,6 +254,7 @@ baz_collection_name_in_asubproject:
updated_at: 2014-04-21 15:37:48 -0400
manifest_text: ". 73feffa4b7f6bb68e44cf984c85f6e88+3 0:3:baz\n"
name: "zzzzz-4zz18-lsitwcf548ui4oe added sometime"
+ properties: {}
empty_collection_name_in_active_user_home_project:
uuid: zzzzz-4zz18-5qa38qghh1j3nvv
@@ -247,6 +265,7 @@ empty_collection_name_in_active_user_home_project:
modified_at: 2014-08-06 22:11:51.242150425 Z
manifest_text: ""
name: Empty collection
+ properties: {}
baz_file_in_asubproject:
uuid: zzzzz-4zz18-0mri2x4u7ftngez
@@ -260,6 +279,7 @@ baz_file_in_asubproject:
updated_at: 2014-02-03T17:22:54Z
manifest_text: ". 73feffa4b7f6bb68e44cf984c85f6e88+3 0:3:baz\n"
name: baz_file
+ properties: {}
collection_to_move_around_in_aproject:
uuid: zzzzz-4zz18-0mri2x4u7ft1234
@@ -273,6 +293,7 @@ collection_to_move_around_in_aproject:
updated_at: 2014-02-03T17:22:54Z
manifest_text: ". 73feffa4b7f6bb68e44cf984c85f6e88+3 0:3:baz\n"
name: collection_to_move_around
+ properties: {}
# Note: collections(:expired_collection) fixture finder won't work
# because it is not in default scope
@@ -292,6 +313,7 @@ expired_collection:
manifest_text: ". 37b51d194a7513e45b56f6524f2d51f2+3 0:3:expired\n"
name: expired_collection
version: 2
+ properties: {}
expired_collection_past_version:
uuid: zzzzz-4zz18-mto52zx1s7oldie
@@ -309,6 +331,7 @@ expired_collection_past_version:
manifest_text: ". 37b51d194a7513e45b56f6524f2d51f2+3 0:3:expired\n"
name: expired_collection original
version: 1
+ properties: {}
trashed_on_next_sweep:
uuid: zzzzz-4zz18-4guozfh77ewd2f0
@@ -325,6 +348,7 @@ trashed_on_next_sweep:
delete_at: 2112-01-01T00:00:00Z
manifest_text: ". 37b51d194a7513e45b56f6524f2d51f2+3 0:3:expired\n"
name: trashed_on_next_sweep
+ properties: {}
# Note: collections(:deleted_on_next_sweep) fixture finder won't work
# because it is not in default scope
@@ -343,6 +367,7 @@ deleted_on_next_sweep:
delete_at: 2016-12-27T22:01:30.234567Z
manifest_text: ". 37b51d194a7513e45b56f6524f2d51f2+3 0:3:expired\n"
name: deleted_on_next_sweep
+ properties: {}
collection_expires_in_future:
uuid: zzzzz-4zz18-padkqo7yb8d9i3j
@@ -358,6 +383,7 @@ collection_expires_in_future:
delete_at: 2038-03-01T00:00:00Z
manifest_text: ". 37b51d194a7513e45b56f6524f2d51f2+3 0:3:expired\n"
name: collection_expires_in_future
+ properties: {}
unique_expired_collection:
uuid: zzzzz-4zz18-mto52zx1s7sn3jk
@@ -374,6 +400,7 @@ unique_expired_collection:
delete_at: 2038-01-01T00:00:00Z
manifest_text: ". 29d7797f1888013986899bc9083783fa+3 0:3:expired\n"
name: unique_expired_collection1
+ properties: {}
unique_expired_collection2:
uuid: zzzzz-4zz18-mto52zx1s7sn3jr
@@ -390,6 +417,7 @@ unique_expired_collection2:
delete_at: 2038-01-01T00:00:00Z
manifest_text: ". 29d7797f1888013986899bc9083783fa+3 0:3:expired\n"
name: unique_expired_collection2
+ properties: {}
# a collection with a log file that can be parsed by the log viewer
# This collection hash matches the following log text:
@@ -406,6 +434,7 @@ real_log_collection:
portable_data_hash: 0b9a7787660e1fce4a93f33e01376ba6+81
manifest_text: ". cdd549ae79fe6640fa3d5c6261d8303c+195 0:195:zzzzz-8i9sb-0vsrcqi7whchuil.log.txt\n"
name: real_log_collection
+ properties: {}
collection_in_home_project_with_same_name_as_in_aproject:
uuid: zzzzz-4zz18-12342x4u7ftabcd
@@ -419,6 +448,7 @@ collection_in_home_project_with_same_name_as_in_aproject:
updated_at: 2014-02-03T17:22:54Z
manifest_text: ". 73feffa4b7f6bb68e44cf984c85f6e88+3 0:3:baz\n"
name: collection_with_same_name_in_aproject_and_home_project
+ properties: {}
collection_in_aproject_with_same_name_as_in_home_project:
uuid: zzzzz-4zz18-56782x4u7ftefgh
@@ -432,6 +462,7 @@ collection_in_aproject_with_same_name_as_in_home_project:
updated_at: 2014-02-03T17:22:54Z
manifest_text: ". 73feffa4b7f6bb68e44cf984c85f6e88+3 0:3:baz\n"
name: collection_with_same_name_in_aproject_and_home_project
+ properties: {}
collection_owned_by_foo:
uuid: zzzzz-4zz18-50surkhkbhsp31b
@@ -442,6 +473,7 @@ collection_owned_by_foo:
created_at: 2014-02-03T17:22:54Z
modified_at: 2014-02-03T17:22:54Z
name: collection_owned_by_foo
+ properties: {}
collection_to_remove_from_subproject:
# The Workbench tests remove this from subproject.
@@ -453,6 +485,7 @@ collection_to_remove_from_subproject:
created_at: 2014-10-15T10:45:00
modified_at: 2014-10-15T10:45:00
name: Collection to remove from subproject
+ properties: {}
collection_with_files_in_subdir:
uuid: zzzzz-4zz18-filesinsubdir00
@@ -466,6 +499,7 @@ collection_with_files_in_subdir:
modified_at: 2014-02-03T17:22:54Z
updated_at: 2014-02-03T17:22:54Z
manifest_text: ". 85877ca2d7e05498dd3d109baf2df106+95 0:95:file_in_subdir1\n./subdir2/subdir3 2bbc341c702df4d8f42ec31f16c10120+64 0:32:file1_in_subdir3.txt 32:32:file2_in_subdir3.txt\n./subdir2/subdir3/subdir4 2bbc341c702df4d8f42ec31f16c10120+64 0:32:file1_in_subdir4.txt 32:32:file2_in_subdir4.txt"
+ properties: {}
graph_test_collection1:
uuid: zzzzz-4zz18-bv31uwvy3neko22
@@ -476,6 +510,7 @@ graph_test_collection1:
name: bar_file
created_at: 2014-02-03T17:22:54Z
modified_at: 2014-02-03T17:22:54Z
+ properties: {}
graph_test_collection2:
uuid: zzzzz-4zz18-uukreo9rbgwsujx
@@ -486,6 +521,7 @@ graph_test_collection2:
name: "FOO General Public License, version 3"
created_at: 2014-02-03T17:22:54Z
modified_at: 2014-02-03T17:22:54Z
+ properties: {}
graph_test_collection3:
uuid: zzzzz-4zz18-uukreo9rbgwsujj
@@ -496,6 +532,7 @@ graph_test_collection3:
name: "baz file"
created_at: 2014-02-03T17:22:54Z
modified_at: 2014-02-03T17:22:54Z
+ properties: {}
collection_1_owned_by_fuse:
uuid: zzzzz-4zz18-ovx05bfzormx3bg
@@ -509,6 +546,7 @@ collection_1_owned_by_fuse:
updated_at: 2014-02-03T17:22:54Z
manifest_text: ". 37b51d194a7513e45b56f6524f2d51f2+3 0:3:bar\n"
name: "collection #1 owned by FUSE"
+ properties: {}
collection_2_owned_by_fuse:
uuid: zzzzz-4zz18-8ubpy4w74twtwzr
@@ -522,6 +560,7 @@ collection_2_owned_by_fuse:
updated_at: 2014-02-03T17:22:54Z
manifest_text: ". acbd18db4cc2f85cedef654fccc4a4d8+3 0:3:foo\n"
name: "collection #2 owned by FUSE"
+ properties: {}
collection_in_fuse_project:
uuid: zzzzz-4zz18-vx4mtkjqfrb534f
@@ -535,6 +574,7 @@ collection_in_fuse_project:
updated_at: 2014-02-03T17:22:54Z
manifest_text: ". 73feffa4b7f6bb68e44cf984c85f6e88+3 0:3:baz\n"
name: "collection in FUSE project"
+ properties: {}
collection_with_no_name_in_aproject:
uuid: zzzzz-4zz18-00000nonamecoll
@@ -545,6 +585,7 @@ collection_with_no_name_in_aproject:
modified_at: 2014-04-21 15:37:48 -0400
updated_at: 2014-04-21 15:37:48 -0400
manifest_text: ". acbd18db4cc2f85cedef654fccc4a4d8+3 0:3:foo\n"
+ properties: {}
collection_to_search_for_in_aproject:
uuid: zzzzz-4zz18-abcd6fx123409f7
@@ -556,6 +597,7 @@ collection_to_search_for_in_aproject:
updated_at: 2014-04-21 15:37:48 -0400
manifest_text: ". acbd18db4cc2f85cedef654fccc4a4d8+3 0:3:foo\n"
name: "zzzzz-4zz18-abcd6fx123409f7 used to search with any"
+ properties: {}
upload_sandbox:
uuid: zzzzz-4zz18-js48y3ykkfdfjd3
@@ -568,6 +610,7 @@ upload_sandbox:
updated_at: 2014-12-09 15:03:16
manifest_text: ''
name: upload sandbox
+ properties: {}
collection_with_unique_words_to_test_full_text_search:
uuid: zzzzz-4zz18-mnt690klmb51aud
@@ -582,6 +625,7 @@ collection_with_unique_words_to_test_full_text_search:
manifest_text: ". 37b51d194a7513e45b56f6524f2d51f2+3 0:3:bar\n"
name: collection_with_some_unique_words
description: The quick_brown_fox jumps over the lazy_dog
+ properties: {}
replication_undesired_unconfirmed:
uuid: zzzzz-4zz18-wjxq7uzx2m9jj4a
@@ -597,6 +641,7 @@ replication_undesired_unconfirmed:
updated_at: 2015-02-07 00:19:28.596236608 Z
manifest_text: ". 37b51d194a7513e45b56f6524f2d51f2+3 0:3:bar\n"
name: replication want=null have=null
+ properties: {}
replication_desired_2_unconfirmed:
uuid: zzzzz-4zz18-3t236wrz4769h7x
@@ -612,6 +657,7 @@ replication_desired_2_unconfirmed:
updated_at: 2015-02-07 00:21:35.050126576 Z
manifest_text: ". 37b51d194a7513e45b56f6524f2d51f2+3 0:3:bar\n"
name: replication want=2 have=null
+ properties: {}
replication_desired_2_confirmed_2:
uuid: zzzzz-4zz18-434zv1tnnf2rygp
@@ -627,6 +673,7 @@ replication_desired_2_confirmed_2:
updated_at: 2015-02-07 00:24:52.983381227 Z
manifest_text: ". acbd18db4cc2f85cedef654fccc4a4d8+3 37b51d194a7513e45b56f6524f2d51f2+3 0:3:foo 3:3:bar\n"
name: replication want=2 have=2
+ properties: {}
storage_classes_desired_default_unconfirmed:
uuid: zzzzz-4zz18-3t236wrz4769tga
@@ -642,6 +689,7 @@ storage_classes_desired_default_unconfirmed:
updated_at: 2015-02-07 00:21:35.050126576 Z
manifest_text: ". 37b51d194a7513e45b56f6524f2d51f2+3 0:3:bar\n"
name: storage classes want=[default] have=[]
+ properties: {}
storage_classes_desired_default_confirmed_default:
uuid: zzzzz-4zz18-3t236wr12769tga
@@ -657,6 +705,7 @@ storage_classes_desired_default_confirmed_default:
updated_at: 2015-02-07 00:21:35.050126576 Z
manifest_text: ". 37b51d194a7513e45b56f6524f2d51f2+3 0:3:bar\n"
name: storage classes want=[default] have=[default]
+ properties: {}
storage_classes_desired_archive_confirmed_default:
uuid: zzzzz-4zz18-3t236wr12769qqa
@@ -672,6 +721,7 @@ storage_classes_desired_archive_confirmed_default:
updated_at: 2015-02-07 00:21:35.050126576 Z
manifest_text: ". 37b51d194a7513e45b56f6524f2d51f2+3 0:3:bar\n"
name: storage classes want=[archive] have=[default]
+ properties: {}
collection_with_empty_properties:
uuid: zzzzz-4zz18-emptyproperties
@@ -728,6 +778,7 @@ collection_with_repeated_filenames_and_contents_in_two_dirs_2:
updated_at: 2014-02-03T17:22:54Z
name: collection_with_repeated_filenames_and_contents_in_two_dirs_2
manifest_text: "./dir1 92b53930db60fe94be2a73fc771ba921+34 0:12:alice 12:12:alice.txt 24:10:carol.txt\n./dir2 56ac2557b1ded11ccab7293dc47d1e88+44 0:27:alice.txt\n"
+ properties: {}
foo_and_bar_files_in_dir:
uuid: zzzzz-4zz18-foonbarfilesdir
@@ -741,6 +792,7 @@ foo_and_bar_files_in_dir:
updated_at: 2014-02-03T17:22:54Z
name: foo_file_in_dir
manifest_text: "./dir1 3858f62230ac3c915f300c664312c63f+6 3:3:bar 0:3:foo\n"
+ properties: {}
multi_level_to_combine:
uuid: zzzzz-4zz18-pyw8yp9g3ujh45f
@@ -754,6 +806,7 @@ multi_level_to_combine:
updated_at: 2014-02-03T17:22:54Z
manifest_text: ". 85877ca2d7e05498dd3d109baf2df106+95 0:0:file1 0:0:file2 0:0:file3\n./dir1 85877ca2d7e05498dd3d109baf2df106+95 0:0:file1 0:0:file2 0:0:file3\n./dir1/subdir 85877ca2d7e05498dd3d109baf2df106+95 0:0:file1 0:0:file2 0:0:file3\n./dir2 85877ca2d7e05498dd3d109baf2df106+95 0:0:file1 0:0:file2 0:0:file3\n"
name: multi_level_to_combine
+ properties: {}
# collection with several file types to test view icon enabled state in collection show page
collection_with_several_supported_file_types:
@@ -768,6 +821,7 @@ collection_with_several_supported_file_types:
updated_at: 2014-02-03T17:22:54Z
manifest_text: ". d41d8cd98f00b204e9800998ecf8427e+0 0:0:file.csv 0:0:file.fa 0:0:file.fasta 0:0:file.gif 0:0:file.json 0:0:file.md 0:0:file.pdf 0:0:file.py 0:0:file.R 0:0:file.sam 0:0:file.sh 0:0:file.tiff 0:0:file.tsv 0:0:file.txt 0:0:file.vcf 0:0:file.xml 0:0:file.xsl 0:0:file.yml\n"
name: collection_with_several_supported_file_types
+ properties: {}
collection_with_several_unsupported_file_types:
uuid: zzzzz-4zz18-supportedtypes2
@@ -781,6 +835,7 @@ collection_with_several_unsupported_file_types:
updated_at: 2014-02-03T17:22:54Z
manifest_text: ". d41d8cd98f00b204e9800998ecf8427e+0 0:0:file 0:0:file.bam\n"
name: collection_with_several_unsupported_file_types
+ properties: {}
collection_not_readable_by_active:
uuid: zzzzz-4zz18-cd42uwvy3neko21
@@ -794,6 +849,7 @@ collection_not_readable_by_active:
updated_at: 2014-02-03T17:22:54Z
manifest_text: ". 37b51d194a7513e45b56f6524f2d51f2+3 0:3:bar\n"
name: collection_not_readable_by_active
+ properties: {}
collection_to_remove_and_rename_files:
uuid: zzzzz-4zz18-a21ux3541sxa8sf
@@ -807,6 +863,7 @@ collection_to_remove_and_rename_files:
updated_at: 2014-02-03T17:22:54Z
manifest_text: ". d41d8cd98f00b204e9800998ecf8427e+0 0:0:file1 0:0:file2\n"
name: collection to remove and rename files
+ properties: {}
collection_with_tags_owned_by_active:
uuid: zzzzz-4zz18-taggedcolletion
@@ -839,6 +896,7 @@ trashed_collection_to_test_name_conflict_on_untrash:
is_trashed: true
trash_at: 2001-01-01T00:00:00Z
delete_at: 2038-01-01T00:00:00Z
+ properties: {}
same_name_as_trashed_coll_to_test_name_conflict_on_untrash:
uuid: zzzzz-4zz18-namesameastrash
@@ -852,6 +910,7 @@ same_name_as_trashed_coll_to_test_name_conflict_on_untrash:
updated_at: 2014-02-03T17:22:54Z
manifest_text: ". d41d8cd98f00b204e9800998ecf8427e+0 0:0:file1 0:0:file2\n"
name: same name for trashed and persisted collections
+ properties: {}
collection_in_trashed_subproject:
uuid: zzzzz-4zz18-trashedproj2col
@@ -865,6 +924,7 @@ collection_in_trashed_subproject:
updated_at: 2014-02-03T17:22:54Z
manifest_text: ". d41d8cd98f00b204e9800998ecf8427e+0 0:0:file1 0:0:file2\n"
name: collection in trashed subproject
+ properties: {}
collection_with_prop1_value1:
uuid: zzzzz-4zz18-withprop1value1
@@ -986,6 +1046,7 @@ collection_<%=i%>_of_10:
owner_uuid: zzzzz-j7d0g-0010collections
created_at: <%= i.minute.ago.to_s(:db) %>
modified_at: <%= i.minute.ago.to_s(:db) %>
+ properties: {}
<% end %>
# collections in project_with_201_collections
@@ -999,6 +1060,7 @@ collection_<%=i%>_of_201:
owner_uuid: zzzzz-j7d0g-0201collections
created_at: <%= i.minute.ago.to_s(:db) %>
modified_at: <%= i.minute.ago.to_s(:db) %>
+ properties: {}
<% end %>
# Do not add your fixtures below this line as the rest of this file will be trimmed by test_helper
diff --git a/services/api/test/fixtures/containers.yml b/services/api/test/fixtures/containers.yml
index 5c5d45f4b..467f81ac9 100644
--- a/services/api/test/fixtures/containers.yml
+++ b/services/api/test/fixtures/containers.yml
@@ -36,6 +36,8 @@ running:
cwd: test
output_path: test
command: ["echo", "hello"]
+ runtime_status:
+ hello: world
runtime_constraints:
ram: 12000000000
vcpus: 4
diff --git a/services/api/test/fixtures/nodes.yml b/services/api/test/fixtures/nodes.yml
index 971132ffe..821a6b5e4 100644
--- a/services/api/test/fixtures/nodes.yml
+++ b/services/api/test/fixtures/nodes.yml
@@ -12,6 +12,7 @@ busy:
last_ping_at: <%= 1.minute.ago.to_s(:db) %>
first_ping_at: <%= 23.hour.ago.to_s(:db) %>
job_uuid: zzzzz-8i9sb-2gx6rz0pjl033w3 # nearly_finished_job
+ properties: {}
info:
ping_secret: "48dpm3b8ijyj3jkr2yczxw0844dqd2752bhll7klodvgz9bg80"
slurm_state: "alloc"
@@ -26,6 +27,7 @@ down:
last_ping_at: <%= 1.hour.ago.to_s(:db) %>
first_ping_at: <%= 23.hour.ago.to_s(:db) %>
job_uuid: ~
+ properties: {}
info:
ping_secret: "2k3i71depad36ugwmlgzilbi4e8n0illb2r8l4efg9mzkb3a1k"
@@ -70,6 +72,7 @@ new_with_no_hostname:
last_ping_at: ~
first_ping_at: ~
job_uuid: ~
+ properties: {}
info:
ping_secret: "abcdyi0x4lb5q4gzqqtrnq30oyj08r8dtdimmanbqw49z1anz2"
@@ -82,6 +85,7 @@ new_with_custom_hostname:
last_ping_at: ~
first_ping_at: ~
job_uuid: ~
+ properties: {}
info:
ping_secret: "abcdyi0x4lb5q4gzqqtrnq30oyj08r8dtdimmanbqw49z1anz2"
@@ -93,5 +97,6 @@ node_with_no_ip_address_yet:
last_ping_at: ~
first_ping_at: ~
job_uuid: ~
+ properties: {}
info:
ping_secret: "abcdyefg4lb5q4gzqqtrnq30oyj08r8dtdimmanbqw49z1anz2"
diff --git a/services/api/test/performance/links_index_test.rb b/services/api/test/performance/links_index_test.rb
index b1b538583..c3f9e9452 100644
--- a/services/api/test/performance/links_index_test.rb
+++ b/services/api/test/performance/links_index_test.rb
@@ -7,12 +7,14 @@ require 'rails/performance_test_help'
class IndexTest < ActionDispatch::PerformanceTest
def test_links_index
- get '/arvados/v1/links', {format: :json}, auth(:admin)
+ get '/arvados/v1/links', params: {format: :json}, headers: auth(:admin)
end
def test_links_index_with_filters
- get '/arvados/v1/links', {format: :json, filters: [%w[head_uuid is_a arvados#collection]].to_json}, auth(:admin)
+ get '/arvados/v1/links',
+ params: {format: :json, filters: [%w[head_uuid is_a arvados#collection]].to_json},
+ headers: auth(:admin)
end
def test_collections_index
- get '/arvados/v1/collections', {format: :json}, auth(:admin)
+ get '/arvados/v1/collections', params: {format: :json}, headers: auth(:admin)
end
end
diff --git a/services/api/test/unit/arvados_model_test.rb b/services/api/test/unit/arvados_model_test.rb
index 3645d0507..0fcdad704 100644
--- a/services/api/test/unit/arvados_model_test.rb
+++ b/services/api/test/unit/arvados_model_test.rb
@@ -140,6 +140,7 @@ class ArvadosModelTest < ActiveSupport::TestCase
all_tables = ActiveRecord::Base.connection.tables
all_tables.delete 'schema_migrations'
all_tables.delete 'permission_refresh_lock'
+ all_tables.delete 'ar_internal_metadata'
all_tables.each do |table|
table_class = table.classify.constantize
diff --git a/services/api/test/unit/container_test.rb b/services/api/test/unit/container_test.rb
index 1a53df7da..5ce3739a3 100644
--- a/services/api/test/unit/container_test.rb
+++ b/services/api/test/unit/container_test.rb
@@ -388,9 +388,11 @@ class ContainerTest < ActiveSupport::TestCase
runtime_status: {'warning' => 'This is not an error'},
progress: 0.15})
c_faster_started_second.update_attributes!({state: Container::Locked})
+ assert_equal 0, Container.where("runtime_status->'error' is not null").count
c_faster_started_second.update_attributes!({state: Container::Running,
runtime_status: {'error' => 'Something bad happened'},
progress: 0.2})
+ assert_equal 1, Container.where("runtime_status->'error' is not null").count
reused = Container.find_reusable(common_attrs)
assert_not_nil reused
# Selected the non-failing container even if it's the one with less progress done
diff --git a/services/api/test/unit/crunch_dispatch_test.rb b/services/api/test/unit/crunch_dispatch_test.rb
index 3460abe3c..42ef0d160 100644
--- a/services/api/test/unit/crunch_dispatch_test.rb
+++ b/services/api/test/unit/crunch_dispatch_test.rb
@@ -79,17 +79,6 @@ class CrunchDispatchTest < ActiveSupport::TestCase
begin
pid = Process.fork do
begin
- # Abandon database connections inherited from parent
- # process. Credit to
- # https://github.com/kstephens/rails_is_forked
- ActiveRecord::Base.connection_handler.connection_pools.each_value do |pool|
- pool.instance_eval do
- @reserved_connections = {}
- @connections = []
- end
- end
- ActiveRecord::Base.establish_connection
-
dispatch = CrunchDispatch.new
dispatch.stubs(:did_recently).returns true
dispatch.run []
diff --git a/services/api/test/unit/job_test.rb b/services/api/test/unit/job_test.rb
index 41e2adb9c..fcbd1722f 100644
--- a/services/api/test/unit/job_test.rb
+++ b/services/api/test/unit/job_test.rb
@@ -661,6 +661,8 @@ class JobTest < ActiveSupport::TestCase
test 'enable legacy api configuration option = auto, has jobs' do
Rails.configuration.enable_legacy_jobs_api = "auto"
+ assert Job.count > 0
+ assert_equal [], Rails.configuration.disable_api_methods
check_enable_legacy_jobs_api
assert_equal [], Rails.configuration.disable_api_methods
end
@@ -670,7 +672,8 @@ class JobTest < ActiveSupport::TestCase
act_as_system_user do
Job.destroy_all
end
- puts "ZZZ #{Job.count}"
+ assert_equal 0, Job.count
+ assert_equal [], Rails.configuration.disable_api_methods
check_enable_legacy_jobs_api
assert_equal Disable_jobs_api_method_list, Rails.configuration.disable_api_methods
end
commit cb4efac6793d18892dde09c631895cb98c3df470
Merge: 728522fbc 5950f9090
Author: Lucas Di Pentima <ldipentima at veritasgenetics.com>
Date: Wed Mar 27 15:20:05 2019 -0300
Merge branch 'master' into 14873-api-rails5-upgrade
Arvados-DCO-1.1-Signed-off-by: Lucas Di Pentima <ldipentima at veritasgenetics.com>
-----------------------------------------------------------------------
hooks/post-receive
--
More information about the arvados-commits
mailing list