summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorsnehaldwivedi <sdwivedi@msystechnologies.com>2020-07-31 04:37:07 -0700
committersnehaldwivedi <sdwivedi@msystechnologies.com>2021-03-25 06:26:26 -0700
commit6ef28f16233d10baacad47cc11afb4b71f6bb3af (patch)
tree3fc0d41abc74138fffdd4e31235dd29faa969195
parentc7da4d865e92ad90488b36b9c04c1c336faedb65 (diff)
downloadchef-6ef28f16233d10baacad47cc11afb4b71f6bb3af.tar.gz
Updated reviewed changes
Signed-off-by: snehaldwivedi <sdwivedi@msystechnologies.com>
-rw-r--r--lib/chef/knife/org_list.rb3
-rw-r--r--lib/chef/knife/user_create.rb2
-rw-r--r--lib/chef/knife/user_delete.rb2
-rw-r--r--lib/chef/knife/user_dissociate.rb2
-rw-r--r--lib/chef/knife/user_edit.rb2
-rw-r--r--lib/chef/knife/user_list.rb2
-rw-r--r--lib/chef/knife/user_show.rb3
-rw-r--r--spec/unit/knife/org_delete_spec.rb2
-rw-r--r--spec/unit/knife/org_list_spec.rb4
-rw-r--r--spec/unit/knife/org_show_spec.rb2
-rw-r--r--spec/unit/knife/user_delete_spec.rb3
-rw-r--r--spec/unit/knife/user_edit_spec.rb2
-rw-r--r--spec/unit/knife/user_list_spec.rb4
-rw-r--r--spec/unit/knife/user_show_spec.rb2
14 files changed, 18 insertions, 17 deletions
diff --git a/lib/chef/knife/org_list.rb b/lib/chef/knife/org_list.rb
index 85a49ee4c5..6f1c4b582b 100644
--- a/lib/chef/knife/org_list.rb
+++ b/lib/chef/knife/org_list.rb
@@ -1,6 +1,6 @@
#
# Author:: Steven Danna (<steve@chef.io>)
-# Copyright:: Copyright (c) Chef Software Inc.
+# Copyright:: Copyright 2011-2016 Chef Software, Inc.
# License:: Apache License, Version 2.0
#
# Licensed under the Apache License, Version 2.0 (the "License");
@@ -15,7 +15,6 @@
# See the License for the specific language governing permissions and
# limitations under the License.
#
-
class Chef
class Knife
class OrgList < Knife
diff --git a/lib/chef/knife/user_create.rb b/lib/chef/knife/user_create.rb
index aa1d4d54f2..701e3f604e 100644
--- a/lib/chef/knife/user_create.rb
+++ b/lib/chef/knife/user_create.rb
@@ -140,4 +140,4 @@ class Chef
end
end
end
-end
+end \ No newline at end of file
diff --git a/lib/chef/knife/user_delete.rb b/lib/chef/knife/user_delete.rb
index 64d729c951..a5554cdd61 100644
--- a/lib/chef/knife/user_delete.rb
+++ b/lib/chef/knife/user_delete.rb
@@ -1,6 +1,6 @@
#
# Author:: Steven Danna (<steve@chef.io>)
-# Copyright:: Copyright (c) Chef Software Inc.
+# Copyright:: Copyright 2011-2016 Chef Software, Inc.
# License:: Apache License, Version 2.0
#
# Licensed under the Apache License, Version 2.0 (the "License");
diff --git a/lib/chef/knife/user_dissociate.rb b/lib/chef/knife/user_dissociate.rb
index 6af1559608..a69394dabd 100644
--- a/lib/chef/knife/user_dissociate.rb
+++ b/lib/chef/knife/user_dissociate.rb
@@ -1,6 +1,6 @@
#
# Author:: Steven Danna (<steve@chef.io>)
-# Copyright:: Copyright (c) Chef Software Inc.
+# Copyright:: Copyright 2011-2016 Chef Software, Inc.
# License:: Apache License, Version 2.0
#
# Licensed under the Apache License, Version 2.0 (the "License");
diff --git a/lib/chef/knife/user_edit.rb b/lib/chef/knife/user_edit.rb
index fff8c6b70f..88202fc81f 100644
--- a/lib/chef/knife/user_edit.rb
+++ b/lib/chef/knife/user_edit.rb
@@ -1,6 +1,6 @@
#
# Author:: Steven Danna (<steve@chef.io>)
-# Copyright:: Copyright (c) Chef Software Inc.
+# Copyright:: Copyright 2011-2016 Chef Software, Inc.
# License:: Apache License, Version 2.0
#
# Licensed under the Apache License, Version 2.0 (the "License");
diff --git a/lib/chef/knife/user_list.rb b/lib/chef/knife/user_list.rb
index 3284964a47..03b46a9f2a 100644
--- a/lib/chef/knife/user_list.rb
+++ b/lib/chef/knife/user_list.rb
@@ -1,6 +1,6 @@
#
# Author:: Steven Danna (<steve@chef.io>)
-# Copyright:: Copyright (c) Chef Software Inc.
+# Copyright:: Copyright 2011-2016 Chef Software, Inc.
# License:: Apache License, Version 2.0
#
# Licensed under the Apache License, Version 2.0 (the "License");
diff --git a/lib/chef/knife/user_show.rb b/lib/chef/knife/user_show.rb
index ea2b06b753..90097df339 100644
--- a/lib/chef/knife/user_show.rb
+++ b/lib/chef/knife/user_show.rb
@@ -1,6 +1,6 @@
#
# Author:: Steven Danna (<steve@chef.io>)
-# Copyright:: Copyright (c) Chef Software Inc.
+# Copyright:: Copyright 2011-2016 Chef Software, Inc.
# License:: Apache License, Version 2.0
#
# Licensed under the Apache License, Version 2.0 (the "License");
@@ -30,6 +30,7 @@ class Chef
long: "--with-orgs",
short: "-l"
+
def run
@user_name = @name_args[0]
diff --git a/spec/unit/knife/org_delete_spec.rb b/spec/unit/knife/org_delete_spec.rb
index baa102f8c8..b8fb372585 100644
--- a/spec/unit/knife/org_delete_spec.rb
+++ b/spec/unit/knife/org_delete_spec.rb
@@ -1,6 +1,6 @@
#
# Author:: Snehal Dwivedi (<sdwivedi@msystechnologies.com>)
-# Copyright:: Copyright (c) Chef Software Inc.
+# Copyright:: Copyright 2014-2016 Chef Software, Inc.
# License:: Apache License, Version 2.0
#
# Licensed under the Apache License, Version 2.0 (the "License");
diff --git a/spec/unit/knife/org_list_spec.rb b/spec/unit/knife/org_list_spec.rb
index de77b4b0c7..0676f64ccc 100644
--- a/spec/unit/knife/org_list_spec.rb
+++ b/spec/unit/knife/org_list_spec.rb
@@ -31,7 +31,9 @@ describe Chef::Knife::OrgList do
end
before :each do
- @org = double("Chef::Org")
+ @rest = double("Chef::ServerAPI")
+ allow(Chef::ServerAPI).to receive(:new).and_return(@rest)
+ allow(@rest).to receive(:get).with("organizations").and_return(orgs)
@knife = Chef::Knife::OrgList.new
expect(Chef::ServerAPI).to receive(:new).with(Chef::Config[:chef_server_root]).and_return(root_rest)
allow(root_rest).to receive(:get).with("organizations").and_return(orgs)
diff --git a/spec/unit/knife/org_show_spec.rb b/spec/unit/knife/org_show_spec.rb
index 2f5246dd84..01bdc34c3b 100644
--- a/spec/unit/knife/org_show_spec.rb
+++ b/spec/unit/knife/org_show_spec.rb
@@ -1,6 +1,6 @@
#
# Author:: Snehal Dwivedi (<sdwivedi@msystechnologies.com>)
-# Copyright:: Copyright (c) Chef Software Inc.
+# Copyright:: Copyright 2011-2016 Chef Software, Inc.
# License:: Apache License, Version 2.0
#
# Licensed under the Apache License, Version 2.0 (the "License");
diff --git a/spec/unit/knife/user_delete_spec.rb b/spec/unit/knife/user_delete_spec.rb
index 4dd2665cda..a9916ad38c 100644
--- a/spec/unit/knife/user_delete_spec.rb
+++ b/spec/unit/knife/user_delete_spec.rb
@@ -1,6 +1,5 @@
#
-# Author:: Steven Danna (<steve@chef.io>)
-# Copyright:: Copyright (c) Chef Software Inc.
+# # Copyright:: Copyright 2014-2016 Chef Software, Inc.
# License:: Apache License, Version 2.0
#
# Licensed under the Apache License, Version 2.0 (the "License");
diff --git a/spec/unit/knife/user_edit_spec.rb b/spec/unit/knife/user_edit_spec.rb
index 2fde328c0c..ddae25846e 100644
--- a/spec/unit/knife/user_edit_spec.rb
+++ b/spec/unit/knife/user_edit_spec.rb
@@ -1,6 +1,6 @@
#
# Author:: Steven Danna (<steve@chef.io>)
-# Copyright:: Copyright (c) Chef Software Inc.
+# Copyright:: Copyright 2011-2016 Chef Software, Inc.
# License:: Apache License, Version 2.0
#
# Licensed under the Apache License, Version 2.0 (the "License");
diff --git a/spec/unit/knife/user_list_spec.rb b/spec/unit/knife/user_list_spec.rb
index 63df590591..d91ec09434 100644
--- a/spec/unit/knife/user_list_spec.rb
+++ b/spec/unit/knife/user_list_spec.rb
@@ -1,6 +1,6 @@
#
-# Author:: Steven Danna
-# Copyright:: Copyright (c) Chef Software Inc.
+# Author:: Snehal Dwivedi (<sdwivedi@msystechnologies.com>)
+# Copyright:: Copyright 2014-2016 Chef Software, Inc.
# License:: Apache License, Version 2.0
#
# Licensed under the Apache License, Version 2.0 (the "License");
diff --git a/spec/unit/knife/user_show_spec.rb b/spec/unit/knife/user_show_spec.rb
index 30742d8c21..0f674ea5dd 100644
--- a/spec/unit/knife/user_show_spec.rb
+++ b/spec/unit/knife/user_show_spec.rb
@@ -1,6 +1,6 @@
#
# Author:: Steven Danna (<steve@chef.io>)
-# Copyright:: Copyright (c) Chef Software Inc.
+# Copyright:: Copyright 2011-2016 Chef Software, Inc.
# License:: Apache License, Version 2.0
#
# Licensed under the Apache License, Version 2.0 (the "License");