merit 2.4.0 → 4.0.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (98) hide show
  1. checksums.yaml +5 -5
  2. data/Gemfile +3 -35
  3. data/NEWS.md +31 -0
  4. data/README.md +15 -3
  5. data/RELEASING.md +16 -0
  6. data/Rakefile +13 -1
  7. data/app/models/merit/badge.rb +2 -19
  8. data/lib/merit.rb +13 -35
  9. data/lib/merit/{rules_badge_methods.rb → badge_rules_methods.rb} +0 -0
  10. data/lib/merit/base_target_finder.rb +1 -6
  11. data/lib/merit/{model_additions.rb → class_methods.rb} +2 -19
  12. data/lib/merit/controller_extensions.rb +13 -30
  13. data/lib/{generators → merit/generators}/active_record/install_generator.rb +12 -8
  14. data/lib/{generators → merit/generators}/active_record/merit_generator.rb +7 -3
  15. data/lib/{generators → merit/generators}/active_record/remove_generator.rb +9 -5
  16. data/lib/{generators/active_record/templates/add_merit_fields_to_model.rb → merit/generators/active_record/templates/add_merit_fields_to_model.erb} +1 -1
  17. data/lib/{generators/active_record/templates/create_badges_sashes.rb → merit/generators/active_record/templates/create_badges_sashes.erb} +1 -1
  18. data/lib/{generators/active_record/templates/create_merit_actions.rb → merit/generators/active_record/templates/create_merit_actions.erb} +2 -2
  19. data/lib/{generators/active_record/templates/create_merit_activity_logs.rb → merit/generators/active_record/templates/create_merit_activity_logs.erb} +1 -1
  20. data/lib/merit/generators/active_record/templates/create_sashes.erb +7 -0
  21. data/lib/{generators/active_record/templates/create_scores_and_points.rb → merit/generators/active_record/templates/create_scores_and_points.erb} +2 -2
  22. data/lib/{generators/active_record/templates/remove_merit_fields_from_model.rb → merit/generators/active_record/templates/remove_merit_fields_from_model.erb} +1 -1
  23. data/lib/{generators/active_record/templates/remove_merit_tables.rb → merit/generators/active_record/templates/remove_merit_tables.erb} +1 -1
  24. data/lib/merit/generators/install_generator.rb +18 -0
  25. data/lib/{generators/merit → merit/generators}/merit_generator.rb +3 -1
  26. data/lib/{generators/merit → merit/generators}/remove_generator.rb +3 -1
  27. data/lib/{generators/merit/templates/merit.rb → merit/generators/templates/merit.erb} +0 -3
  28. data/lib/{generators/merit/templates/merit_badge_rules.rb → merit/generators/templates/merit_badge_rules.erb} +0 -0
  29. data/lib/{generators/merit/templates/merit_point_rules.rb → merit/generators/templates/merit_point_rules.erb} +0 -0
  30. data/lib/{generators/merit/templates/merit_rank_rules.rb → merit/generators/templates/merit_rank_rules.erb} +0 -0
  31. data/{app/models/merit/action.rb → lib/merit/models/action_concern.rb} +12 -10
  32. data/lib/merit/models/active_record/action.rb +11 -0
  33. data/lib/merit/models/active_record/{merit/activity_log.rb → activity_log.rb} +4 -6
  34. data/lib/merit/models/active_record/{merit/badges_sash.rb → badges_sash.rb} +4 -4
  35. data/lib/merit/models/active_record/{merit/sash.rb → sash.rb} +5 -2
  36. data/lib/merit/models/active_record/{merit/score.rb → score.rb} +4 -1
  37. data/lib/merit/models/badges_sash_concern.rb +13 -0
  38. data/lib/merit/models/base/badges_sash.rb +1 -1
  39. data/lib/merit/models/base/sash.rb +1 -1
  40. data/lib/merit/models/sash_concern.rb +53 -0
  41. data/lib/merit/{rules_points_methods.rb → point_rules_methods.rb} +0 -0
  42. data/lib/merit/{rules_rank_methods.rb → rank_rules_methods.rb} +3 -18
  43. data/merit.gemspec +7 -5
  44. data/test/dummy/app/controllers/comments_controller.rb +1 -1
  45. data/test/dummy/app/controllers/registrations_controller.rb +1 -1
  46. data/test/dummy/app/models/address.rb +1 -12
  47. data/test/dummy/app/models/comment.rb +3 -25
  48. data/test/dummy/app/models/user.rb +1 -18
  49. data/test/dummy/config/application.rb +8 -10
  50. data/test/dummy/config/application_api_only.rb +28 -0
  51. data/test/dummy/config/environment_api_only.rb +7 -0
  52. data/test/dummy/config/environments/test.rb +1 -1
  53. data/test/dummy/config/initializers/new_framework_defaults.rb +3 -0
  54. data/test/dummy/db/migrate/20110421191249_create_users.rb +2 -2
  55. data/test/dummy/db/migrate/20110421191250_create_comments.rb +2 -2
  56. data/test/dummy/db/migrate/20120318022220_add_fields_to_users.rb +1 -1
  57. data/test/dummy/db/migrate/20130321082817_add_fields_to_comments.rb +1 -1
  58. data/test/dummy/db/migrate/20130329224406_create_merit_actions.rb +2 -2
  59. data/test/dummy/db/migrate/20130329224407_create_merit_activity_logs.rb +1 -1
  60. data/test/dummy/db/migrate/20130329224408_create_sashes.rb +2 -2
  61. data/test/dummy/db/migrate/20130329224409_create_badges_sashes.rb +1 -1
  62. data/test/dummy/db/migrate/20130329224410_create_scores_and_points.rb +1 -1
  63. data/test/dummy/db/migrate/20140211144001_create_addresses.rb +1 -1
  64. data/test/dummy/db/migrate/20140819133931_add_target_data_to_merit_actions.rb +1 -1
  65. data/test/dummy/db/schema.rb +55 -59
  66. data/test/integration/navigation_test.rb +2 -2
  67. data/test/test_helper.rb +11 -12
  68. data/test/unit/base_target_finder_test.rb +7 -26
  69. data/test/unit/merit_unit_test.rb +13 -17
  70. data/test/unit/rule_unit_test.rb +15 -8
  71. data/test/unit/rules_matcher_test.rb +9 -6
  72. data/test/unit/sash_finder_test.rb +5 -5
  73. data/test/unit/score_test.rb +1 -1
  74. data/test/unit/target_finder_test.rb +13 -13
  75. metadata +61 -70
  76. data/UPGRADING.md +0 -256
  77. data/lib/generators/active_record/templates/add_target_data_to_merit_actions.rb +0 -5
  78. data/lib/generators/active_record/templates/create_sashes.rb +0 -7
  79. data/lib/generators/active_record/upgrade_generator.rb +0 -36
  80. data/lib/generators/merit/install_generator.rb +0 -16
  81. data/lib/generators/merit/upgrade_generator.rb +0 -7
  82. data/lib/merit/models/active_record/merit/action.rb +0 -12
  83. data/lib/merit/models/mongoid/merit/action.rb +0 -18
  84. data/lib/merit/models/mongoid/merit/activity_log.rb +0 -11
  85. data/lib/merit/models/mongoid/merit/badges_sash.rb +0 -22
  86. data/lib/merit/models/mongoid/merit/sash.rb +0 -30
  87. data/lib/merit/models/mongoid/merit/score.rb +0 -45
  88. data/test/dummy/db/migrate/20140906225844_create_players.rb +0 -8
  89. data/test/dummy/public/javascripts/application.js +0 -2
  90. data/test/dummy/public/javascripts/controls.js +0 -965
  91. data/test/dummy/public/javascripts/dragdrop.js +0 -974
  92. data/test/dummy/public/javascripts/effects.js +0 -1123
  93. data/test/dummy/public/javascripts/prototype.js +0 -6001
  94. data/test/dummy/public/javascripts/rails.js +0 -191
  95. data/test/orm/active_record.rb +0 -2
  96. data/test/orm/mongoid.rb +0 -6
  97. data/test/orm_models/active_record.rb +0 -11
  98. data/test/orm_models/mongoid.rb +0 -15

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.