summaryrefslogtreecommitdiff
path: root/spec/unit/knife/user_create_spec.rb
Commit message (Collapse)AuthorAgeFilesLines
* Remove copyright dateslcg/remove-copyright-datesLamont Granquist2020-04-131-1/+1
| | | | | | | | Legally incredibly dubious, particularly since we don't follow it strictly as policy, and we have git history instead, which does it right. This is just a waste of time and a cargo cult. Signed-off-by: Lamont Granquist <lamont@scriptkiddie.org>
* Remove knife user support for open source Chef Server < 12Tim Smith2018-11-041-30/+0
| | | | | | We shipped Chef 12 server on 2014-11-25. We've maintained backwards compatibility here by shipping double plugins, constantly checking for Chef 11 and then rewriting passed args. We deprecated it with Chef 14. This fully removes support. chef-client will continue to work on chef 11, but users cannot be managed with knife from a workstation running the latest version of Chef/ChefDK. Signed-off-by: Tim Smith <tsmith@chef.io>
* fix Style/BlockDelimiters, Style/MultilineBlockLayout and 0.42.0 engine upgradeLamont Granquist2016-08-171-4/+4
| | | | Signed-off-by: Lamont Granquist <lamont@scriptkiddie.org>
* Be way more explicit about how we're handling datatm/missed_migrationThom May2016-02-151-1/+1
| | | | | | | This just codifies the behaviour we're actually using - that we're passing a json string and expecting a hash back. Also adds a deprecation warning to the use of Chef::JSONCompat.from_json
* autofixing auto-inserted delimiterslcg/chefstyle-batchLamont Granquist2016-02-091-5/+5
|
* auto fixing some rubocopsLamont Granquist2016-02-091-5/+5
| | | | | | | | | Style/NegatedWhile Style/ParenthesesAroundCondition Style/WhileUntilDo Style/WordArray Performance/ReverseEach Style/ColonMethodCall
* autofixing whitespace copsLamont Granquist2016-02-051-3/+3
| | | | | | | | | | | | | | | | | | | | | | 4174 Style/SpaceInsideHashLiteralBraces 1860 Style/SpaceAroundOperators 1336 Style/SpaceInsideBlockBraces 1292 Style/AlignHash 997 Style/SpaceAfterComma 860 Style/SpaceAroundEqualsInParameterDefault 310 Style/EmptyLines 294 Style/IndentationConsistency 267 Style/TrailingWhitespace 238 Style/ExtraSpacing 212 Style/SpaceBeforeBlockBraces 166 Style/MultilineOperationIndentation 144 Style/TrailingBlankLines 120 Style/EmptyLineBetweenDefs 101 Style/IndentationWidth 82 Style/SpaceAroundBlockParameters 40 Style/EmptyLinesAroundMethodBody 29 Style/EmptyLinesAroundAccessModifier 1 Style/RescueEnsureAlignment
* Copyright year update for 2016 and massive cleanup.Noah Kantrowitz2016-02-021-1/+1
| | | Generated via git ls-files | xargs perl -pi -e "s/[Cc]opyright (?:\([Cc]\) )?((?\!$(date +%Y))\\d{4})(-\\d{4})?([, ][ \d]+)*(,|(?= ))/Copyright \\1-$(date +%Y),/g"
* Use double quotes by defaultThom May2016-01-141-26/+26
| | | | | | | This is an entirely mechanically generated (chefstyle -a) change, to go along with chef/chefstyle#5 . We should pick something and use it consistently, and my opinion is that double quotes are the appropriate thing.
* Move Chef::OscUser back to Chef::User namespace and new user code to ↵tylercloke2015-07-061-1/+1
| | | | | | Chef::UserV1. Also, have Chef::User (formally Chef::OscUser) use API V0 to make requests.
* Backwards compatible support for OSC 11 in knife user commands.tylercloke2015-06-051-8/+31
| | | | All knife user commands can detect when they have failed for OSC 11 reasons and forward the request to backwards compatible knife osc_user commands.
* API V1 support for client creation.tylercloke2015-06-051-47/+21
|
* Added V1 support to Chef::User.update and removed admin field.tylercloke2015-06-051-18/+0
|
* Added versioned Chef Object API support code and repaired Chef::User.create.tylercloke2015-06-051-48/+195
| | | | Also added Chef::User.create V1 API support. Chef::User.create will attempt to use V1 of the server API, and if it fails, it will fall back to V0.
* Update to RSpec 3.Claire McQuin2014-10-291-18/+18
|
* Update tests for CHEF-4760 change.Chris Jerdonek2014-07-211-1/+1
|
* Supress stdout/err output from knife testsdanielsdeleo2014-04-241-4/+6
|
* s/mock\(/double(/gLamont Granquist2014-01-291-1/+1
|
* s/stub!/stub/gLamont Granquist2014-01-291-6/+6
| | | | fix deprecation warnings
* Fix up knife user public key test for windows pathsBryan McLellan2013-02-071-1/+1
|
* Add validation of password length to the user-create plugin.Steven Danna2013-02-061-0/+9
| | | | | | Ideally this type of validation would be done somewhere in the model. Currently our use of the set_or_return method doesn't easily allow for these types of validations.
* Add user commands to knife.Steven Danna2013-02-061-0/+77
This commit adds the following commands to knife: knife user list knife user show USERNAME knife user create USERNAME knife user delete USERNAME knife user reregister USERNAME Note that since Chef::User objects do not contain a json_class, the edit object method will not work as expecated.