diff options
author | Lamont Granquist <lamont@scriptkiddie.org> | 2017-07-20 14:36:06 -0700 |
---|---|---|
committer | Lamont Granquist <lamont@scriptkiddie.org> | 2017-07-20 14:36:06 -0700 |
commit | f0973fc7c597905f786a2fbe6f241cd972c6a336 (patch) | |
tree | 43f0b8da9af5d3c92e2862de6880cf674827a935 /spec/unit/cookbook/metadata_spec.rb | |
parent | 30cc959bde0f00293cd28a77963f12a29b0086df (diff) | |
download | chef-f0973fc7c597905f786a2fbe6f241cd972c6a336.tar.gz |
chef server rejects metadata with nil maintainer
chef server returns a 400. we could prune nil values out of the
JSON but then it'd be difficult to specify a "null" JSON value if we
really needed one. seems better to follow the pattern of using
empty string here (which i tested against Hosted and works).
Signed-off-by: Lamont Granquist <lamont@scriptkiddie.org>
Diffstat (limited to 'spec/unit/cookbook/metadata_spec.rb')
-rw-r--r-- | spec/unit/cookbook/metadata_spec.rb | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/spec/unit/cookbook/metadata_spec.rb b/spec/unit/cookbook/metadata_spec.rb index 2fdc43c289..a91feec26d 100644 --- a/spec/unit/cookbook/metadata_spec.rb +++ b/spec/unit/cookbook/metadata_spec.rb @@ -1,7 +1,7 @@ # # Author:: Adam Jacob (<adam@chef.io>) # Author:: Seth Falcon (<seth@chef.io>) -# Copyright:: Copyright 2008-2016, Chef Software, Inc. +# Copyright:: Copyright 2008-2017, Chef Software Inc. # License:: Apache License, Version 2.0 # # Licensed under the Apache License, Version 2.0 (the "License"); @@ -98,11 +98,11 @@ describe Chef::Cookbook::Metadata do end it "has an empty maintainer field" do - expect(metadata.maintainer).to eq(nil) + expect(metadata.maintainer).to eq("") end it "has an empty maintainer_email field" do - expect(metadata.maintainer).to eq(nil) + expect(metadata.maintainer_email).to eq("") end it "has an empty platforms list" do |