active_admin-state_machine 0.1.0 → 1.0.0.pre3

Sign up to get free protection for your applications and to get access to all the features.
Files changed (202) hide show
  1. checksums.yaml +5 -5
  2. data/CHANGELOG.md +9 -0
  3. data/README.md +56 -8
  4. data/lib/active_admin/state_machine/dsl.rb +7 -2
  5. data/lib/active_admin/state_machine/version.rb +3 -1
  6. data/lib/active_admin/state_machine.rb +7 -0
  7. metadata +106 -441
  8. data/Rakefile +0 -17
  9. data/spec/dummy/README.rdoc +0 -261
  10. data/spec/dummy/Rakefile +0 -7
  11. data/spec/dummy/app/admin/admin_users.rb +0 -20
  12. data/spec/dummy/app/admin/categories.rb +0 -5
  13. data/spec/dummy/app/admin/dashboard.rb +0 -33
  14. data/spec/dummy/app/admin/posts.rb +0 -21
  15. data/spec/dummy/app/assets/javascripts/active_admin.js +0 -1
  16. data/spec/dummy/app/assets/javascripts/application.js +0 -15
  17. data/spec/dummy/app/assets/stylesheets/active_admin.css.scss +0 -29
  18. data/spec/dummy/app/assets/stylesheets/application.css +0 -13
  19. data/spec/dummy/app/controllers/application_controller.rb +0 -3
  20. data/spec/dummy/app/helpers/application_helper.rb +0 -2
  21. data/spec/dummy/app/models/ability.rb +0 -12
  22. data/spec/dummy/app/models/admin_user.rb +0 -11
  23. data/spec/dummy/app/models/category.rb +0 -4
  24. data/spec/dummy/app/models/post.rb +0 -31
  25. data/spec/dummy/app/views/layouts/application.html.erb +0 -14
  26. data/spec/dummy/config/application.rb +0 -65
  27. data/spec/dummy/config/boot.rb +0 -10
  28. data/spec/dummy/config/database.sample.yml +0 -25
  29. data/spec/dummy/config/database.travis.yml +0 -4
  30. data/spec/dummy/config/database.yml +0 -12
  31. data/spec/dummy/config/environment.rb +0 -5
  32. data/spec/dummy/config/environments/development.rb +0 -38
  33. data/spec/dummy/config/environments/production.rb +0 -67
  34. data/spec/dummy/config/environments/test.rb +0 -37
  35. data/spec/dummy/config/initializers/active_admin.rb +0 -211
  36. data/spec/dummy/config/initializers/backtrace_silencers.rb +0 -7
  37. data/spec/dummy/config/initializers/devise.rb +0 -252
  38. data/spec/dummy/config/initializers/inflections.rb +0 -15
  39. data/spec/dummy/config/initializers/mime_types.rb +0 -5
  40. data/spec/dummy/config/initializers/secret_token.rb +0 -7
  41. data/spec/dummy/config/initializers/session_store.rb +0 -8
  42. data/spec/dummy/config/initializers/wrap_parameters.rb +0 -14
  43. data/spec/dummy/config/locales/devise.en.yml +0 -59
  44. data/spec/dummy/config/locales/en.yml +0 -10
  45. data/spec/dummy/config/routes.rb +0 -61
  46. data/spec/dummy/config.ru +0 -4
  47. data/spec/dummy/db/development.sqlite3 +0 -0
  48. data/spec/dummy/db/migrate/20130817004304_devise_create_admin_users.rb +0 -52
  49. data/spec/dummy/db/migrate/20130817004306_create_admin_notes.rb +0 -17
  50. data/spec/dummy/db/migrate/20130817004307_move_admin_notes_to_comments.rb +0 -26
  51. data/spec/dummy/db/migrate/20130817005638_create_posts.rb +0 -11
  52. data/spec/dummy/db/migrate/20130829000200_create_categories.rb +0 -11
  53. data/spec/dummy/db/migrate/20131025231118_add_super_admin_to_admin_users.rb +0 -5
  54. data/spec/dummy/db/schema.rb +0 -65
  55. data/spec/dummy/db/seeds.rb +0 -1
  56. data/spec/dummy/db/test.sqlite3 +0 -0
  57. data/spec/dummy/log/development.log +0 -9116
  58. data/spec/dummy/log/test.log +0 -2969
  59. data/spec/dummy/public/404.html +0 -26
  60. data/spec/dummy/public/422.html +0 -26
  61. data/spec/dummy/public/500.html +0 -25
  62. data/spec/dummy/public/favicon.ico +0 -0
  63. data/spec/dummy/script/rails +0 -6
  64. data/spec/dummy/tmp/cache/assets/C6E/0F0/sprockets%2F930c17aa4002b266315478d747cec213 +0 -0
  65. data/spec/dummy/tmp/cache/assets/CA3/0F0/sprockets%2F6111c5f7d680071cae83281d5237bb52 +0 -0
  66. data/spec/dummy/tmp/cache/assets/CAE/C10/sprockets%2Fa28299b4afd821b21049164940fe6a29 +0 -0
  67. data/spec/dummy/tmp/cache/assets/CDB/040/sprockets%2Fc732474e67003a4eb840eb44c5ca9385 +0 -0
  68. data/spec/dummy/tmp/cache/assets/CE1/700/sprockets%2F9e9ac16860d51b9e1245e02a8bd98125 +0 -0
  69. data/spec/dummy/tmp/cache/assets/CE6/660/sprockets%2F90e738777deb87d405d03a2f251b547d +0 -0
  70. data/spec/dummy/tmp/cache/assets/CED/B50/sprockets%2F23b334e745d2ceb50b677668a367de99 +0 -0
  71. data/spec/dummy/tmp/cache/assets/CF3/0A0/sprockets%2F75abab8c479e90729ca78828102e5e78 +0 -0
  72. data/spec/dummy/tmp/cache/assets/CF6/EE0/sprockets%2F3f96414b8e9655fb831972cc81b6b95d +0 -0
  73. data/spec/dummy/tmp/cache/assets/D00/800/sprockets%2F5fe66f0484322d5cda7408c0cb030c36 +0 -0
  74. data/spec/dummy/tmp/cache/assets/D09/E60/sprockets%2Fd61ab529e52f740f6d26a7b3bc082914 +0 -0
  75. data/spec/dummy/tmp/cache/assets/D0B/400/sprockets%2Ff4f1a7e6cca869f56232e07440d0242e +0 -0
  76. data/spec/dummy/tmp/cache/assets/D0D/8D0/sprockets%2Fb048e1909af567b1e61c8f18dd3b4134 +0 -0
  77. data/spec/dummy/tmp/cache/assets/D0E/750/sprockets%2F535f852b14c3f64b6d4498e281ba6aa3 +0 -0
  78. data/spec/dummy/tmp/cache/assets/D1B/330/sprockets%2Fb7c84f061393bf7dac846cd173863c57 +0 -0
  79. data/spec/dummy/tmp/cache/assets/D20/AE0/sprockets%2F25d0f6af9dd375937908ad493464d3ce +0 -0
  80. data/spec/dummy/tmp/cache/assets/D2F/A20/sprockets%2F006e5a12b1bb0fc15555ad556589be6b +0 -0
  81. data/spec/dummy/tmp/cache/assets/D38/540/sprockets%2F86e1ad844bc9df4491a2a52b870421db +0 -0
  82. data/spec/dummy/tmp/cache/assets/D3E/AA0/sprockets%2F77115ed12f0f2812dd9284b1badf974e +0 -0
  83. data/spec/dummy/tmp/cache/assets/D45/B50/sprockets%2F3eb36e58b929a7cb215ec6cd90730f38 +0 -0
  84. data/spec/dummy/tmp/cache/assets/D45/BD0/sprockets%2F2def1531b613ed7a7dbfb87119f63667 +0 -0
  85. data/spec/dummy/tmp/cache/assets/D48/640/sprockets%2F9f4f18d910b678b1d0777e04cdaf6f24 +0 -0
  86. data/spec/dummy/tmp/cache/assets/D4C/C80/sprockets%2F298e59aa2551dcef562bdfd65908462d +0 -0
  87. data/spec/dummy/tmp/cache/assets/D59/D70/sprockets%2Fed9f0de1b65ae8d7ef89087c83728461 +0 -0
  88. data/spec/dummy/tmp/cache/assets/D63/930/sprockets%2F8877deb95181465893a12fc98feefea9 +0 -0
  89. data/spec/dummy/tmp/cache/assets/D67/9A0/sprockets%2F2b5fbe497968ed201d0ff0dca410d319 +0 -0
  90. data/spec/dummy/tmp/cache/assets/D78/560/sprockets%2Fdbe66652ccfa390de76149634dd82e1f +0 -0
  91. data/spec/dummy/tmp/cache/assets/D93/4C0/sprockets%2F857ecd2092cee11f740b3cf2e373ad2a +0 -0
  92. data/spec/dummy/tmp/cache/assets/D9A/FA0/sprockets%2Fe32c0ff23c6a4084195aafcff444fe63 +0 -0
  93. data/spec/dummy/tmp/cache/assets/DA3/450/sprockets%2Ff6563ad6efdc449e5219ea221c75fcc3 +0 -0
  94. data/spec/dummy/tmp/cache/assets/DA4/050/sprockets%2Fb09f488a4f238bf22bc82cef50a6f84d +0 -0
  95. data/spec/dummy/tmp/cache/assets/DD7/FE0/sprockets%2Ff00de35ea71cb4fc5fc5e96860f5ee55 +0 -0
  96. data/spec/dummy/tmp/cache/assets/DDE/420/sprockets%2Ffb8b186d5bf0307f86f65fc787d2adeb +0 -0
  97. data/spec/dummy/tmp/cache/assets/DE6/B50/sprockets%2Febd2b61aa5d1e7bd84e31523e1bc71ac +0 -0
  98. data/spec/dummy/tmp/cache/assets/DF0/870/sprockets%2F1e4ab2eb47da0bb42b6e37e38639cbae +0 -0
  99. data/spec/dummy/tmp/cache/assets/DFA/CD0/sprockets%2F6bb1e8a62edbd48cf00dc678d1f0f65a +0 -0
  100. data/spec/dummy/tmp/cache/assets/E32/990/sprockets%2F2f6fe5d3fae5b4dba7e7cc36ca68e415 +0 -0
  101. data/spec/dummy/tmp/cache/sass/021f0a44d22f3712e4de7c01de2d6b99f65f2482/_bourbon-deprecated-upcoming.scssc +0 -0
  102. data/spec/dummy/tmp/cache/sass/021f0a44d22f3712e4de7c01de2d6b99f65f2482/_bourbon.scssc +0 -0
  103. data/spec/dummy/tmp/cache/sass/0733f78978a3764d0f20e2bea650007fb2bf064b/_compact.scssc +0 -0
  104. data/spec/dummy/tmp/cache/sass/0733f78978a3764d0f20e2bea650007fb2bf064b/_flex-grid.scssc +0 -0
  105. data/spec/dummy/tmp/cache/sass/0733f78978a3764d0f20e2bea650007fb2bf064b/_grid-width.scssc +0 -0
  106. data/spec/dummy/tmp/cache/sass/0733f78978a3764d0f20e2bea650007fb2bf064b/_linear-gradient.scssc +0 -0
  107. data/spec/dummy/tmp/cache/sass/0733f78978a3764d0f20e2bea650007fb2bf064b/_modular-scale.scssc +0 -0
  108. data/spec/dummy/tmp/cache/sass/0733f78978a3764d0f20e2bea650007fb2bf064b/_px-to-em.scssc +0 -0
  109. data/spec/dummy/tmp/cache/sass/0733f78978a3764d0f20e2bea650007fb2bf064b/_radial-gradient.scssc +0 -0
  110. data/spec/dummy/tmp/cache/sass/0733f78978a3764d0f20e2bea650007fb2bf064b/_tint-shade.scssc +0 -0
  111. data/spec/dummy/tmp/cache/sass/0733f78978a3764d0f20e2bea650007fb2bf064b/_transition-property-name.scssc +0 -0
  112. data/spec/dummy/tmp/cache/sass/2fd82df35090e4bb74fb9a41455f20a1e79db68a/_batch_actions.css.scssc +0 -0
  113. data/spec/dummy/tmp/cache/sass/2fd82df35090e4bb74fb9a41455f20a1e79db68a/_blank_slates.scssc +0 -0
  114. data/spec/dummy/tmp/cache/sass/2fd82df35090e4bb74fb9a41455f20a1e79db68a/_breadcrumbs.scssc +0 -0
  115. data/spec/dummy/tmp/cache/sass/2fd82df35090e4bb74fb9a41455f20a1e79db68a/_buttons.scssc +0 -0
  116. data/spec/dummy/tmp/cache/sass/2fd82df35090e4bb74fb9a41455f20a1e79db68a/_columns.scssc +0 -0
  117. data/spec/dummy/tmp/cache/sass/2fd82df35090e4bb74fb9a41455f20a1e79db68a/_comments.css.scssc +0 -0
  118. data/spec/dummy/tmp/cache/sass/2fd82df35090e4bb74fb9a41455f20a1e79db68a/_date_picker.css.scssc +0 -0
  119. data/spec/dummy/tmp/cache/sass/2fd82df35090e4bb74fb9a41455f20a1e79db68a/_dropdown_menu.scssc +0 -0
  120. data/spec/dummy/tmp/cache/sass/2fd82df35090e4bb74fb9a41455f20a1e79db68a/_flash_messages.css.scssc +0 -0
  121. data/spec/dummy/tmp/cache/sass/2fd82df35090e4bb74fb9a41455f20a1e79db68a/_grid.scssc +0 -0
  122. data/spec/dummy/tmp/cache/sass/2fd82df35090e4bb74fb9a41455f20a1e79db68a/_index_list.scssc +0 -0
  123. data/spec/dummy/tmp/cache/sass/2fd82df35090e4bb74fb9a41455f20a1e79db68a/_links.scssc +0 -0
  124. data/spec/dummy/tmp/cache/sass/2fd82df35090e4bb74fb9a41455f20a1e79db68a/_pagination.scssc +0 -0
  125. data/spec/dummy/tmp/cache/sass/2fd82df35090e4bb74fb9a41455f20a1e79db68a/_panels.scssc +0 -0
  126. data/spec/dummy/tmp/cache/sass/2fd82df35090e4bb74fb9a41455f20a1e79db68a/_popovers.css.scssc +0 -0
  127. data/spec/dummy/tmp/cache/sass/2fd82df35090e4bb74fb9a41455f20a1e79db68a/_scopes.scssc +0 -0
  128. data/spec/dummy/tmp/cache/sass/2fd82df35090e4bb74fb9a41455f20a1e79db68a/_status_tags.scssc +0 -0
  129. data/spec/dummy/tmp/cache/sass/2fd82df35090e4bb74fb9a41455f20a1e79db68a/_table_tools.css.scssc +0 -0
  130. data/spec/dummy/tmp/cache/sass/2fd82df35090e4bb74fb9a41455f20a1e79db68a/_tables.css.scssc +0 -0
  131. data/spec/dummy/tmp/cache/sass/49a924645aad7b7327372ccd94e45cbdf78ae4ff/_all.css.scssc +0 -0
  132. data/spec/dummy/tmp/cache/sass/49a924645aad7b7327372ccd94e45cbdf78ae4ff/_buttons.css.scssc +0 -0
  133. data/spec/dummy/tmp/cache/sass/49a924645aad7b7327372ccd94e45cbdf78ae4ff/_gradients.css.scssc +0 -0
  134. data/spec/dummy/tmp/cache/sass/49a924645aad7b7327372ccd94e45cbdf78ae4ff/_icons.css.scssc +0 -0
  135. data/spec/dummy/tmp/cache/sass/49a924645aad7b7327372ccd94e45cbdf78ae4ff/_reset.css.scssc +0 -0
  136. data/spec/dummy/tmp/cache/sass/49a924645aad7b7327372ccd94e45cbdf78ae4ff/_rounded.css.scssc +0 -0
  137. data/spec/dummy/tmp/cache/sass/49a924645aad7b7327372ccd94e45cbdf78ae4ff/_sections.css.scssc +0 -0
  138. data/spec/dummy/tmp/cache/sass/49a924645aad7b7327372ccd94e45cbdf78ae4ff/_shadows.css.scssc +0 -0
  139. data/spec/dummy/tmp/cache/sass/49a924645aad7b7327372ccd94e45cbdf78ae4ff/_typography.scssc +0 -0
  140. data/spec/dummy/tmp/cache/sass/49a924645aad7b7327372ccd94e45cbdf78ae4ff/_utilities.scssc +0 -0
  141. data/spec/dummy/tmp/cache/sass/49a924645aad7b7327372ccd94e45cbdf78ae4ff/_variables.css.scssc +0 -0
  142. data/spec/dummy/tmp/cache/sass/97d1d5c145c2924a55e7b5d99d290112170b74f0/_footer.scssc +0 -0
  143. data/spec/dummy/tmp/cache/sass/97d1d5c145c2924a55e7b5d99d290112170b74f0/_main_structure.scssc +0 -0
  144. data/spec/dummy/tmp/cache/sass/97d1d5c145c2924a55e7b5d99d290112170b74f0/_title_bar.scssc +0 -0
  145. data/spec/dummy/tmp/cache/sass/a88ac2680a1680d7d2a5f8b0c7dc7f5e3131ade5/_button.scssc +0 -0
  146. data/spec/dummy/tmp/cache/sass/a88ac2680a1680d7d2a5f8b0c7dc7f5e3131ade5/_clearfix.scssc +0 -0
  147. data/spec/dummy/tmp/cache/sass/a88ac2680a1680d7d2a5f8b0c7dc7f5e3131ade5/_font-family.scssc +0 -0
  148. data/spec/dummy/tmp/cache/sass/a88ac2680a1680d7d2a5f8b0c7dc7f5e3131ade5/_hide-text.scssc +0 -0
  149. data/spec/dummy/tmp/cache/sass/a88ac2680a1680d7d2a5f8b0c7dc7f5e3131ade5/_html5-input-types.scssc +0 -0
  150. data/spec/dummy/tmp/cache/sass/a88ac2680a1680d7d2a5f8b0c7dc7f5e3131ade5/_position.scssc +0 -0
  151. data/spec/dummy/tmp/cache/sass/a88ac2680a1680d7d2a5f8b0c7dc7f5e3131ade5/_prefixer.scssc +0 -0
  152. data/spec/dummy/tmp/cache/sass/a88ac2680a1680d7d2a5f8b0c7dc7f5e3131ade5/_retina-image.scssc +0 -0
  153. data/spec/dummy/tmp/cache/sass/a88ac2680a1680d7d2a5f8b0c7dc7f5e3131ade5/_size.scssc +0 -0
  154. data/spec/dummy/tmp/cache/sass/a88ac2680a1680d7d2a5f8b0c7dc7f5e3131ade5/_timing-functions.scssc +0 -0
  155. data/spec/dummy/tmp/cache/sass/a88ac2680a1680d7d2a5f8b0c7dc7f5e3131ade5/_triangle.scssc +0 -0
  156. data/spec/dummy/tmp/cache/sass/c10713f51b89c2fd0ebe39519f07849be30ad7dc/_deprecated-webkit-gradient.scssc +0 -0
  157. data/spec/dummy/tmp/cache/sass/c10713f51b89c2fd0ebe39519f07849be30ad7dc/_gradient-positions-parser.scssc +0 -0
  158. data/spec/dummy/tmp/cache/sass/c10713f51b89c2fd0ebe39519f07849be30ad7dc/_linear-positions-parser.scssc +0 -0
  159. data/spec/dummy/tmp/cache/sass/c10713f51b89c2fd0ebe39519f07849be30ad7dc/_radial-arg-parser.scssc +0 -0
  160. data/spec/dummy/tmp/cache/sass/c10713f51b89c2fd0ebe39519f07849be30ad7dc/_radial-positions-parser.scssc +0 -0
  161. data/spec/dummy/tmp/cache/sass/c10713f51b89c2fd0ebe39519f07849be30ad7dc/_render-gradients.scssc +0 -0
  162. data/spec/dummy/tmp/cache/sass/c10713f51b89c2fd0ebe39519f07849be30ad7dc/_shape-size-stripper.scssc +0 -0
  163. data/spec/dummy/tmp/cache/sass/c440ddc8eb3b4ee623e7dfe6ab824cc1e13dc16d/_animation.scssc +0 -0
  164. data/spec/dummy/tmp/cache/sass/c440ddc8eb3b4ee623e7dfe6ab824cc1e13dc16d/_appearance.scssc +0 -0
  165. data/spec/dummy/tmp/cache/sass/c440ddc8eb3b4ee623e7dfe6ab824cc1e13dc16d/_backface-visibility.scssc +0 -0
  166. data/spec/dummy/tmp/cache/sass/c440ddc8eb3b4ee623e7dfe6ab824cc1e13dc16d/_background-image.scssc +0 -0
  167. data/spec/dummy/tmp/cache/sass/c440ddc8eb3b4ee623e7dfe6ab824cc1e13dc16d/_background.scssc +0 -0
  168. data/spec/dummy/tmp/cache/sass/c440ddc8eb3b4ee623e7dfe6ab824cc1e13dc16d/_border-image.scssc +0 -0
  169. data/spec/dummy/tmp/cache/sass/c440ddc8eb3b4ee623e7dfe6ab824cc1e13dc16d/_border-radius.scssc +0 -0
  170. data/spec/dummy/tmp/cache/sass/c440ddc8eb3b4ee623e7dfe6ab824cc1e13dc16d/_box-sizing.scssc +0 -0
  171. data/spec/dummy/tmp/cache/sass/c440ddc8eb3b4ee623e7dfe6ab824cc1e13dc16d/_columns.scssc +0 -0
  172. data/spec/dummy/tmp/cache/sass/c440ddc8eb3b4ee623e7dfe6ab824cc1e13dc16d/_flex-box.scssc +0 -0
  173. data/spec/dummy/tmp/cache/sass/c440ddc8eb3b4ee623e7dfe6ab824cc1e13dc16d/_font-face.scssc +0 -0
  174. data/spec/dummy/tmp/cache/sass/c440ddc8eb3b4ee623e7dfe6ab824cc1e13dc16d/_hidpi-media-query.scssc +0 -0
  175. data/spec/dummy/tmp/cache/sass/c440ddc8eb3b4ee623e7dfe6ab824cc1e13dc16d/_image-rendering.scssc +0 -0
  176. data/spec/dummy/tmp/cache/sass/c440ddc8eb3b4ee623e7dfe6ab824cc1e13dc16d/_inline-block.scssc +0 -0
  177. data/spec/dummy/tmp/cache/sass/c440ddc8eb3b4ee623e7dfe6ab824cc1e13dc16d/_keyframes.scssc +0 -0
  178. data/spec/dummy/tmp/cache/sass/c440ddc8eb3b4ee623e7dfe6ab824cc1e13dc16d/_linear-gradient.scssc +0 -0
  179. data/spec/dummy/tmp/cache/sass/c440ddc8eb3b4ee623e7dfe6ab824cc1e13dc16d/_perspective.scssc +0 -0
  180. data/spec/dummy/tmp/cache/sass/c440ddc8eb3b4ee623e7dfe6ab824cc1e13dc16d/_placeholder.scssc +0 -0
  181. data/spec/dummy/tmp/cache/sass/c440ddc8eb3b4ee623e7dfe6ab824cc1e13dc16d/_radial-gradient.scssc +0 -0
  182. data/spec/dummy/tmp/cache/sass/c440ddc8eb3b4ee623e7dfe6ab824cc1e13dc16d/_transform.scssc +0 -0
  183. data/spec/dummy/tmp/cache/sass/c440ddc8eb3b4ee623e7dfe6ab824cc1e13dc16d/_transition.scssc +0 -0
  184. data/spec/dummy/tmp/cache/sass/c440ddc8eb3b4ee623e7dfe6ab824cc1e13dc16d/_user-select.scssc +0 -0
  185. data/spec/dummy/tmp/cache/sass/c7fb764b3bec96a92cf65b0d831789c5ca3c5ed7/active_admin.css.scssc +0 -0
  186. data/spec/dummy/tmp/cache/sass/cb0cbb3d3d7b7c51feca169c780bb955b45511b4/_dashboard.scssc +0 -0
  187. data/spec/dummy/tmp/cache/sass/cb0cbb3d3d7b7c51feca169c780bb955b45511b4/_logged_out.scssc +0 -0
  188. data/spec/dummy/tmp/cache/sass/eeb938f07a558025f0485a33a8e74dcc19262df9/_base.css.scssc +0 -0
  189. data/spec/dummy/tmp/cache/sass/eeb938f07a558025f0485a33a8e74dcc19262df9/_forms.css.scssc +0 -0
  190. data/spec/dummy/tmp/cache/sass/eeb938f07a558025f0485a33a8e74dcc19262df9/_header.css.scssc +0 -0
  191. data/spec/dummy/tmp/cache/sass/eeb938f07a558025f0485a33a8e74dcc19262df9/_mixins.css.scssc +0 -0
  192. data/spec/dummy/tmp/cache/sass/eeb938f07a558025f0485a33a8e74dcc19262df9/_typography.css.scssc +0 -0
  193. data/spec/dummy/tmp/cache/sass/eeb938f07a558025f0485a33a8e74dcc19262df9/print.css.scssc +0 -0
  194. data/spec/dummy/tmp/pids/server.pid +0 -1
  195. data/spec/factories/admin_users.rb +0 -8
  196. data/spec/factories/categories.rb +0 -17
  197. data/spec/factories/posts.rb +0 -11
  198. data/spec/features/authorization_spec.rb +0 -23
  199. data/spec/features/custom_block_spec.rb +0 -25
  200. data/spec/features/js_confirmation_spec.rb +0 -51
  201. data/spec/spec_helper.rb +0 -54
  202. data/spec/support/post_helpers.rb +0 -22
@@ -1,12 +0,0 @@
1
- class Ability
2
- include CanCan::Ability
3
-
4
- def initialize(user)
5
- if user.super_admin?
6
- can :manage, :all
7
- else
8
- can :read, ActiveAdmin::Page, name: "Dashboard"
9
- can [:read, :show, :index], [Category, Post]
10
- end
11
- end
12
- end
@@ -1,11 +0,0 @@
1
- class AdminUser < ActiveRecord::Base
2
- # Include default devise modules. Others available are:
3
- # :token_authenticatable, :confirmable,
4
- # :lockable, :timeoutable and :omniauthable
5
- devise :database_authenticatable,
6
- :recoverable, :rememberable, :trackable, :validatable
7
-
8
- # Setup accessible (or protected) attributes for your model
9
- attr_accessible :email, :password, :password_confirmation, :remember_me
10
- # attr_accessible :title, :body
11
- end
@@ -1,4 +0,0 @@
1
- class Category < ActiveRecord::Base
2
- attr_accessible :name
3
- has_many :posts
4
- end
@@ -1,31 +0,0 @@
1
- class Post < ActiveRecord::Base
2
- attr_accessible :body, :status, :title
3
-
4
- belongs_to :category
5
-
6
- validates :title, presence: true, uniqueness: true
7
- validates :body, presence: true
8
-
9
- DRAFT = 'draft'
10
- REVIEWED = 'reviewed'
11
- PUBLISHED = 'published'
12
- ARCHIVED = 'archived'
13
-
14
- state_machine :status, initial: DRAFT do
15
- event :peer_review do
16
- transition DRAFT => REVIEWED
17
- end
18
-
19
- event :publish do
20
- transition REVIEWED => PUBLISHED
21
- end
22
-
23
- event :archive do
24
- transition any - ARCHIVED => ARCHIVED
25
- end
26
-
27
- event :reopen do
28
- transition any - DRAFT => DRAFT
29
- end
30
- end
31
- end
@@ -1,14 +0,0 @@
1
- <!DOCTYPE html>
2
- <html>
3
- <head>
4
- <title>Dummy</title>
5
- <%= stylesheet_link_tag "application", :media => "all" %>
6
- <%= javascript_include_tag "application" %>
7
- <%= csrf_meta_tags %>
8
- </head>
9
- <body>
10
-
11
- <%= yield %>
12
-
13
- </body>
14
- </html>
@@ -1,65 +0,0 @@
1
- require File.expand_path('../boot', __FILE__)
2
-
3
- # Pick the frameworks you want:
4
- require "active_record/railtie"
5
- require "action_controller/railtie"
6
- require "action_mailer/railtie"
7
- require "active_resource/railtie"
8
- require "sprockets/railtie"
9
- # require "rails/test_unit/railtie"
10
-
11
- Bundler.require(*Rails.groups)
12
- require "active_admin/state_machine"
13
-
14
- module Dummy
15
- class Application < Rails::Application
16
- # Settings in config/environments/* take precedence over those specified here.
17
- # Application configuration should go into files in config/initializers
18
- # -- all .rb files in that directory are automatically loaded.
19
-
20
- # Custom directories with classes and modules you want to be autoloadable.
21
- # config.autoload_paths += %W(#{config.root}/extras)
22
-
23
- # Only load the plugins named here, in the order given (default is alphabetical).
24
- # :all can be used as a placeholder for all plugins not explicitly named.
25
- # config.plugins = [ :exception_notification, :ssl_requirement, :all ]
26
-
27
- # Activate observers that should always be running.
28
- # config.active_record.observers = :cacher, :garbage_collector, :forum_observer
29
-
30
- # Set Time.zone default to the specified zone and make Active Record auto-convert to this zone.
31
- # Run "rake -D time" for a list of tasks for finding time zone names. Default is UTC.
32
- # config.time_zone = 'Central Time (US & Canada)'
33
-
34
- # The default locale is :en and all translations from config/locales/*.rb,yml are auto loaded.
35
- # config.i18n.load_path += Dir[Rails.root.join('my', 'locales', '*.{rb,yml}').to_s]
36
- # config.i18n.default_locale = :de
37
-
38
- # Configure the default encoding used in templates for Ruby 1.9.
39
- config.encoding = "utf-8"
40
-
41
- # Configure sensitive parameters which will be filtered from the log file.
42
- config.filter_parameters += [:password]
43
-
44
- # Enable escaping HTML in JSON.
45
- config.active_support.escape_html_entities_in_json = true
46
-
47
- # Use SQL instead of Active Record's schema dumper when creating the database.
48
- # This is necessary if your schema can't be completely dumped by the schema dumper,
49
- # like if you have constraints or database-specific column types
50
- # config.active_record.schema_format = :sql
51
-
52
- # Enforce whitelist mode for mass assignment.
53
- # This will create an empty whitelist of attributes available for mass-assignment for all models
54
- # in your app. As such, your models will need to explicitly whitelist or blacklist accessible
55
- # parameters by using an attr_accessible or attr_protected declaration.
56
- config.active_record.whitelist_attributes = true
57
-
58
- # Enable the asset pipeline
59
- config.assets.enabled = true
60
-
61
- # Version of your assets, change this if you want to expire all your assets
62
- config.assets.version = '1.0'
63
- end
64
- end
65
-
@@ -1,10 +0,0 @@
1
- require 'rubygems'
2
- gemfile = File.expand_path('../../../../Gemfile', __FILE__)
3
-
4
- if File.exist?(gemfile)
5
- ENV['BUNDLE_GEMFILE'] = gemfile
6
- require 'bundler'
7
- Bundler.setup
8
- end
9
-
10
- $:.unshift File.expand_path('../../../../lib', __FILE__)
@@ -1,25 +0,0 @@
1
- # SQLite version 3.x
2
- # gem install sqlite3
3
- #
4
- # Ensure the SQLite 3 gem is defined in your Gemfile
5
- # gem 'sqlite3'
6
- development:
7
- adapter: sqlite3
8
- database: db/development.sqlite3
9
- pool: 5
10
- timeout: 5000
11
-
12
- # Warning: The database defined as "test" will be erased and
13
- # re-generated from your development database when you run "rake".
14
- # Do not set this db to the same as development or production.
15
- test:
16
- adapter: sqlite3
17
- database: db/test.sqlite3
18
- pool: 5
19
- timeout: 5000
20
-
21
- production:
22
- adapter: sqlite3
23
- database: db/production.sqlite3
24
- pool: 5
25
- timeout: 5000
@@ -1,4 +0,0 @@
1
- test:
2
- adapter: postgresql
3
- database: aa_state_machine_test
4
- username: postgres
@@ -1,12 +0,0 @@
1
- pg: &pg
2
- adapter: postgresql
3
- encoding: unicode
4
- pool: 5
5
-
6
- development:
7
- <<: *pg
8
- database: active_admin_state_machine_development
9
-
10
- test:
11
- <<: *pg
12
- database: active_admin_state_machine_test
@@ -1,5 +0,0 @@
1
- # Load the rails application
2
- require File.expand_path('../application', __FILE__)
3
-
4
- # Initialize the rails application
5
- Dummy::Application.initialize!
@@ -1,38 +0,0 @@
1
- require 'pry'
2
- Dummy::Application.configure do
3
- # Settings specified here will take precedence over those in config/application.rb
4
-
5
- # In the development environment your application's code is reloaded on
6
- # every request. This slows down response time but is perfect for development
7
- # since you don't have to restart the web server when you make code changes.
8
- config.cache_classes = false
9
-
10
- # Log error messages when you accidentally call methods on nil.
11
- config.whiny_nils = true
12
-
13
- # Show full error reports and disable caching
14
- config.consider_all_requests_local = true
15
- config.action_controller.perform_caching = false
16
-
17
- # Don't care if the mailer can't send
18
- config.action_mailer.raise_delivery_errors = false
19
-
20
- # Print deprecation notices to the Rails logger
21
- config.active_support.deprecation = :log
22
-
23
- # Only use best-standards-support built into browsers
24
- config.action_dispatch.best_standards_support = :builtin
25
-
26
- # Raise exception on mass assignment protection for Active Record models
27
- config.active_record.mass_assignment_sanitizer = :strict
28
-
29
- # Log the query plan for queries taking more than this (works
30
- # with SQLite, MySQL, and PostgreSQL)
31
- config.active_record.auto_explain_threshold_in_seconds = 0.5
32
-
33
- # Do not compress assets
34
- config.assets.compress = false
35
-
36
- # Expands the lines which load the assets
37
- config.assets.debug = true
38
- end
@@ -1,67 +0,0 @@
1
- Dummy::Application.configure do
2
- # Settings specified here will take precedence over those in config/application.rb
3
-
4
- # Code is not reloaded between requests
5
- config.cache_classes = true
6
-
7
- # Full error reports are disabled and caching is turned on
8
- config.consider_all_requests_local = false
9
- config.action_controller.perform_caching = true
10
-
11
- # Disable Rails's static asset server (Apache or nginx will already do this)
12
- config.serve_static_assets = false
13
-
14
- # Compress JavaScripts and CSS
15
- config.assets.compress = true
16
-
17
- # Don't fallback to assets pipeline if a precompiled asset is missed
18
- config.assets.compile = false
19
-
20
- # Generate digests for assets URLs
21
- config.assets.digest = true
22
-
23
- # Defaults to nil and saved in location specified by config.assets.prefix
24
- # config.assets.manifest = YOUR_PATH
25
-
26
- # Specifies the header that your server uses for sending files
27
- # config.action_dispatch.x_sendfile_header = "X-Sendfile" # for apache
28
- # config.action_dispatch.x_sendfile_header = 'X-Accel-Redirect' # for nginx
29
-
30
- # Force all access to the app over SSL, use Strict-Transport-Security, and use secure cookies.
31
- # config.force_ssl = true
32
-
33
- # See everything in the log (default is :info)
34
- # config.log_level = :debug
35
-
36
- # Prepend all log lines with the following tags
37
- # config.log_tags = [ :subdomain, :uuid ]
38
-
39
- # Use a different logger for distributed setups
40
- # config.logger = ActiveSupport::TaggedLogging.new(SyslogLogger.new)
41
-
42
- # Use a different cache store in production
43
- # config.cache_store = :mem_cache_store
44
-
45
- # Enable serving of images, stylesheets, and JavaScripts from an asset server
46
- # config.action_controller.asset_host = "http://assets.example.com"
47
-
48
- # Precompile additional assets (application.js, application.css, and all non-JS/CSS are already added)
49
- # config.assets.precompile += %w( search.js )
50
-
51
- # Disable delivery errors, bad email addresses will be ignored
52
- # config.action_mailer.raise_delivery_errors = false
53
-
54
- # Enable threaded mode
55
- # config.threadsafe!
56
-
57
- # Enable locale fallbacks for I18n (makes lookups for any locale fall back to
58
- # the I18n.default_locale when a translation can not be found)
59
- config.i18n.fallbacks = true
60
-
61
- # Send deprecation notices to registered listeners
62
- config.active_support.deprecation = :notify
63
-
64
- # Log the query plan for queries taking more than this (works
65
- # with SQLite, MySQL, and PostgreSQL)
66
- # config.active_record.auto_explain_threshold_in_seconds = 0.5
67
- end
@@ -1,37 +0,0 @@
1
- Dummy::Application.configure do
2
- # Settings specified here will take precedence over those in config/application.rb
3
-
4
- # The test environment is used exclusively to run your application's
5
- # test suite. You never need to work with it otherwise. Remember that
6
- # your test database is "scratch space" for the test suite and is wiped
7
- # and recreated between test runs. Don't rely on the data there!
8
- config.cache_classes = true
9
-
10
- # Configure static asset server for tests with Cache-Control for performance
11
- config.serve_static_assets = true
12
- config.static_cache_control = "public, max-age=3600"
13
-
14
- # Log error messages when you accidentally call methods on nil
15
- config.whiny_nils = true
16
-
17
- # Show full error reports and disable caching
18
- config.consider_all_requests_local = true
19
- config.action_controller.perform_caching = false
20
-
21
- # Raise exceptions instead of rendering exception templates
22
- config.action_dispatch.show_exceptions = false
23
-
24
- # Disable request forgery protection in test environment
25
- config.action_controller.allow_forgery_protection = false
26
-
27
- # Tell Action Mailer not to deliver emails to the real world.
28
- # The :test delivery method accumulates sent emails in the
29
- # ActionMailer::Base.deliveries array.
30
- config.action_mailer.delivery_method = :test
31
-
32
- # Raise exception on mass assignment protection for Active Record models
33
- config.active_record.mass_assignment_sanitizer = :strict
34
-
35
- # Print deprecation notices to the stderr
36
- config.active_support.deprecation = :stderr
37
- end
@@ -1,211 +0,0 @@
1
- ActiveAdmin.setup do |config|
2
-
3
- # == Site Title
4
- #
5
- # Set the title that is displayed on the main layout
6
- # for each of the active admin pages.
7
- #
8
- config.site_title = "Dummy"
9
-
10
- # Set the link url for the title. For example, to take
11
- # users to your main site. Defaults to no link.
12
- #
13
- # config.site_title_link = "/"
14
-
15
- # Set an optional image to be displayed for the header
16
- # instead of a string (overrides :site_title)
17
- #
18
- # Note: Recommended image height is 21px to properly fit in the header
19
- #
20
- # config.site_title_image = "/images/logo.png"
21
-
22
- # == Default Namespace
23
- #
24
- # Set the default namespace each administration resource
25
- # will be added to.
26
- #
27
- # eg:
28
- # config.default_namespace = :hello_world
29
- #
30
- # This will create resources in the HelloWorld module and
31
- # will namespace routes to /hello_world/*
32
- #
33
- # To set no namespace by default, use:
34
- # config.default_namespace = false
35
- #
36
- # Default:
37
- # config.default_namespace = :admin
38
- #
39
- # You can customize the settings for each namespace by using
40
- # a namespace block. For example, to change the site title
41
- # within a namespace:
42
- #
43
- # config.namespace :admin do |admin|
44
- # admin.site_title = "Custom Admin Title"
45
- # end
46
- #
47
- # This will ONLY change the title for the admin section. Other
48
- # namespaces will continue to use the main "site_title" configuration.
49
-
50
- # == User Authentication
51
- #
52
- # Active Admin will automatically call an authentication
53
- # method in a before filter of all controller actions to
54
- # ensure that there is a currently logged in admin user.
55
- #
56
- # This setting changes the method which Active Admin calls
57
- # within the controller.
58
- config.authentication_method = :authenticate_admin_user!
59
-
60
-
61
- # == Current User
62
- #
63
- # Active Admin will associate actions with the current
64
- # user performing them.
65
- #
66
- # This setting changes the method which Active Admin calls
67
- # to return the currently logged in user.
68
- config.current_user_method = :current_admin_user
69
-
70
-
71
- # == Logging Out
72
- #
73
- # Active Admin displays a logout link on each screen. These
74
- # settings configure the location and method used for the link.
75
- #
76
- # This setting changes the path where the link points to. If it's
77
- # a string, the strings is used as the path. If it's a Symbol, we
78
- # will call the method to return the path.
79
- #
80
- # Default:
81
- config.logout_link_path = :destroy_admin_user_session_path
82
-
83
- # This setting changes the http method used when rendering the
84
- # link. For example :get, :delete, :put, etc..
85
- #
86
- # Default:
87
- # config.logout_link_method = :get
88
-
89
- # == Root
90
- #
91
- # Set the action to call for the root path. You can set different
92
- # roots for each namespace.
93
- #
94
- # Default:
95
- # config.root_to = 'dashboard#index'
96
-
97
- # == Admin Comments
98
- #
99
- # Admin comments allow you to add comments to any model for admin use.
100
- # Admin comments are enabled by default.
101
- #
102
- # Default:
103
- config.allow_comments = false
104
- #
105
- # You can turn them on and off for any given namespace by using a
106
- # namespace config block.
107
- #
108
- # Eg:
109
- # config.namespace :without_comments do |without_comments|
110
- # without_comments.allow_comments = false
111
- # end
112
-
113
-
114
- # == Batch Actions
115
- #
116
- # Enable and disable Batch Actions
117
- #
118
- config.batch_actions = true
119
-
120
-
121
- # == Controller Filters
122
- #
123
- # You can add before, after and around filters to all of your
124
- # Active Admin resources and pages from here.
125
- #
126
- # config.before_filter :do_something_awesome
127
-
128
-
129
- # == Register Stylesheets & Javascripts
130
- #
131
- # We recommend using the built in Active Admin layout and loading
132
- # up your own stylesheets / javascripts to customize the look
133
- # and feel.
134
- #
135
- # To load a stylesheet:
136
- # config.register_stylesheet 'my_stylesheet.css'
137
-
138
- # You can provide an options hash for more control, which is passed along to stylesheet_link_tag():
139
- # config.register_stylesheet 'my_print_stylesheet.css', :media => :print
140
- #
141
- # To load a javascript file:
142
- # config.register_javascript 'my_javascript.js'
143
-
144
-
145
- # == CSV options
146
- #
147
- # Set the CSV builder separator (default is ",")
148
- # config.csv_column_separator = ','
149
- #
150
- # Set the CSV builder options (default is {})
151
- # config.csv_options = {}
152
-
153
-
154
- # == Menu System
155
- #
156
- # You can add a navigation menu to be used in your application, or configure a provided menu
157
- #
158
- # To change the default utility navigation to show a link to your website & a logout btn
159
- #
160
- # config.namespace :admin do |admin|
161
- # admin.build_menu :utility_navigation do |menu|
162
- # menu.add label: "My Great Website", url: "http://www.mygreatwebsite.com", html_options: { target: :blank }
163
- # admin.add_logout_button_to_menu menu
164
- # end
165
- # end
166
- #
167
- # If you wanted to add a static menu item to the default menu provided:
168
- #
169
- # config.namespace :admin do |admin|
170
- # admin.build_menu :default do |menu|
171
- # menu.add label: "My Great Website", url: "http://www.mygreatwebsite.com", html_options: { target: :blank }
172
- # end
173
- # end
174
-
175
- # == Download Links
176
- #
177
- # You can disable download links on resource listing pages,
178
- # or customize the formats shown per namespace/globally
179
- #
180
- # To disable/customize for the :admin namespace:
181
- #
182
- # config.namespace :admin do |admin|
183
- #
184
- # # Disable the links entirely
185
- # admin.download_links = false
186
- #
187
- # # Only show XML & PDF options
188
- # admin.download_links = [:xml, :pdf]
189
- #
190
- # end
191
-
192
-
193
- # == Pagination
194
- #
195
- # Pagination is enabled by default for all resources.
196
- # You can control the default per page count for all resources here.
197
- #
198
- # config.default_per_page = 30
199
-
200
-
201
- # == Filters
202
- #
203
- # By default the index screen includes a “Filters” sidebar on the right
204
- # hand side with a filter for each attribute of the registered model.
205
- # You can enable or disable them for all resources here.
206
- #
207
- # config.filters = true
208
-
209
- config.authorization_adapter = "ActiveAdmin::CanCanAdapter"
210
-
211
- end