Merge branch 'master' into 2903-remove-pi-active-and-success
[arvados.git] / services / api / test / integration / serialized_encoding_test.rb
1 require 'test_helper'
2
3 class SerializedEncodingTest < ActionDispatch::IntegrationTest
4   fixtures :all
5
6   test "store json-encoded link with properties hash" do
7     post "/arvados/v1/links", {
8       :link => {
9         :link_class => 'test',
10         :name => 'test',
11         :properties => {:foo => :bar}
12       }.to_json,
13       :format => :json
14     }, auth(:active)
15     assert_response :success
16   end
17
18   test "store json-encoded pipeline instance with components_summary hash" do
19     post "/arvados/v1/pipeline_instances", {
20       :pipeline_instance => {
21         :components_summary => {:todo => 0}
22       }.to_json,
23       :format => :json
24     }, auth(:active)
25     assert_response :success
26   end
27 end