spice 1.0.0.rc → 1.0.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (109) hide show
  1. data/.gitignore +2 -0
  2. data/Gemfile +0 -14
  3. data/README.md +1 -1
  4. data/Rakefile +1 -1
  5. data/TODO.md +2 -1
  6. data/lib/spice.rb +47 -72
  7. data/lib/spice/authentication.rb +23 -45
  8. data/lib/spice/base.rb +104 -0
  9. data/lib/spice/client.rb +8 -48
  10. data/lib/spice/config.rb +37 -19
  11. data/lib/spice/connection.rb +33 -117
  12. data/lib/spice/connection/clients.rb +26 -6
  13. data/lib/spice/connection/cookbooks.rb +19 -14
  14. data/lib/spice/connection/data_bags.rb +31 -20
  15. data/lib/spice/connection/environments.rb +6 -7
  16. data/lib/spice/connection/nodes.rb +23 -6
  17. data/lib/spice/connection/roles.rb +5 -5
  18. data/lib/spice/connection/search.rb +12 -12
  19. data/lib/spice/cookbook.rb +3 -29
  20. data/lib/spice/cookbook_version.rb +9 -61
  21. data/lib/spice/core_ext/array.rb +7 -0
  22. data/lib/spice/core_ext/enumerable.rb +11 -0
  23. data/lib/spice/core_ext/hash.rb +49 -0
  24. data/lib/spice/core_ext/mash.rb +219 -0
  25. data/lib/spice/data_bag.rb +3 -37
  26. data/lib/spice/data_bag_item.rb +7 -47
  27. data/lib/spice/environment.rb +12 -27
  28. data/lib/spice/error.rb +22 -10
  29. data/lib/spice/identity_map.rb +8 -0
  30. data/lib/spice/node.rb +13 -34
  31. data/lib/spice/request.rb +73 -11
  32. data/lib/spice/response/parse_json.rb +8 -3
  33. data/lib/spice/role.rb +8 -33
  34. data/lib/spice/version.rb +1 -1
  35. data/spec/fixtures/client.pem +27 -0
  36. data/spec/fixtures/clients/create.json +4 -0
  37. data/spec/fixtures/clients/index.json +5 -0
  38. data/spec/fixtures/clients/reregister.json +5 -0
  39. data/spec/fixtures/clients/show.json +8 -0
  40. data/spec/fixtures/clients/update.json +5 -0
  41. data/spec/fixtures/cookbook_versions/show.json +108 -0
  42. data/spec/fixtures/cookbook_versions/update.json +62 -0
  43. data/spec/fixtures/cookbooks/index-0.10.json +28 -0
  44. data/spec/fixtures/cookbooks/index-0.9.json +4 -0
  45. data/spec/fixtures/cookbooks/show-0.10.json +15 -0
  46. data/spec/fixtures/cookbooks/show-apache2-0.9.json +5 -0
  47. data/spec/fixtures/cookbooks/show-unicorn-0.9.json +5 -0
  48. data/spec/fixtures/data_bag_items/create.json +1 -0
  49. data/spec/fixtures/data_bag_items/show.json +4 -0
  50. data/spec/fixtures/data_bag_items/update.json +4 -0
  51. data/spec/fixtures/data_bags/create.json +3 -0
  52. data/spec/fixtures/data_bags/index.json +3 -0
  53. data/spec/fixtures/data_bags/show.json +3 -0
  54. data/spec/fixtures/environments/cookbook.json +15 -0
  55. data/spec/fixtures/environments/cookbooks.json +28 -0
  56. data/spec/fixtures/environments/create.json +1 -0
  57. data/spec/fixtures/environments/delete.json +8 -0
  58. data/spec/fixtures/environments/index.json +3 -0
  59. data/spec/fixtures/environments/show.json +8 -0
  60. data/spec/fixtures/environments/update.json +8 -0
  61. data/spec/fixtures/nodes/cookbooks.json +41 -0
  62. data/spec/fixtures/nodes/create.json +1 -0
  63. data/spec/fixtures/nodes/delete.json +17 -0
  64. data/spec/fixtures/nodes/index.json +3 -0
  65. data/spec/fixtures/nodes/show.json +17 -0
  66. data/spec/fixtures/nodes/update.json +13 -0
  67. data/spec/fixtures/roles/create.json +1 -0
  68. data/spec/fixtures/roles/delete.json +11 -0
  69. data/spec/fixtures/roles/index.json +3 -0
  70. data/spec/fixtures/roles/show.json +12 -0
  71. data/spec/fixtures/roles/update.json +11 -0
  72. data/spec/fixtures/search/client.json +1 -0
  73. data/spec/fixtures/search/data_bag.json +1 -0
  74. data/spec/fixtures/search/environment.json +1 -0
  75. data/spec/fixtures/search/node.json +1 -0
  76. data/spec/fixtures/search/role.json +1 -0
  77. data/spec/spec_helper.rb +5 -4
  78. data/spec/spice/base_spec.rb +34 -0
  79. data/spec/spice/client_spec.rb +0 -61
  80. data/spec/spice/config_spec.rb +14 -0
  81. data/spec/spice/connection/clients_spec.rb +82 -0
  82. data/spec/spice/connection/cookbooks_spec.rb +86 -0
  83. data/spec/spice/connection/data_bags_spec.rb +126 -0
  84. data/spec/spice/connection_spec.rb +63 -0
  85. data/spec/spice/cookbook_spec.rb +0 -61
  86. data/spec/spice/data_bag_item_spec.rb +7 -0
  87. data/spec/spice/data_bag_spec.rb +0 -160
  88. data/spec/spice/environment_spec.rb +0 -89
  89. data/spec/spice/node_spec.rb +0 -74
  90. data/spec/spice/role_spec.rb +0 -61
  91. data/spec/spice_spec.rb +8 -116
  92. data/spec/support/helpers.rb +58 -0
  93. data/spice.gemspec +13 -15
  94. metadata +227 -87
  95. data/.watchr +0 -22
  96. data/lib/spice/connection/authentication.rb +0 -47
  97. data/lib/spice/mock.rb +0 -46
  98. data/lib/spice/persistence.rb +0 -62
  99. data/spec/spice/chef_spec.rb +0 -52
  100. data/spec/spice/search_spec.rb +0 -2
  101. data/spec/support/chef_requests.rb +0 -0
  102. data/spec/support/client_requests.rb +0 -95
  103. data/spec/support/cookbook_requests.rb +0 -95
  104. data/spec/support/data_bag_item_requests.rb +0 -138
  105. data/spec/support/data_bag_requests.rb +0 -95
  106. data/spec/support/environment_requests.rb +0 -221
  107. data/spec/support/node_requests.rb +0 -138
  108. data/spec/support/respond_with_matcher.rb +0 -53
  109. data/spec/support/role_requests.rb +0 -95

There are too many changes on this page to be displayed.


The amount of changes on this page would crash your brower.

You can still verify the content by downloading the gem file manually.