guacamole 0.2.0 → 0.3.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (50) hide show
  1. checksums.yaml +4 -4
  2. data/.hound.yml +3 -0
  3. data/{config/reek.yml → .reek.yml} +5 -0
  4. data/.travis.yml +3 -0
  5. data/CHANGELOG.md +19 -0
  6. data/GOALS.md +20 -0
  7. data/Gemfile +1 -11
  8. data/Guardfile +0 -4
  9. data/README.md +147 -11
  10. data/Rakefile +33 -3
  11. data/guacamole.gemspec +12 -1
  12. data/lib/guacamole.rb +1 -0
  13. data/lib/guacamole/callbacks.rb +259 -0
  14. data/lib/guacamole/collection.rb +50 -32
  15. data/lib/guacamole/configuration.rb +92 -15
  16. data/lib/guacamole/model.rb +39 -1
  17. data/lib/guacamole/railtie.rb +9 -3
  18. data/lib/guacamole/version.rb +1 -1
  19. data/lib/rails/generators/guacamole/callbacks/callbacks_generator.rb +26 -0
  20. data/lib/rails/generators/guacamole/callbacks/templates/callbacks.rb.tt +13 -0
  21. data/lib/rails/generators/rspec/callbacks/callbacks_generator.rb +14 -0
  22. data/lib/rails/generators/rspec/callbacks/templates/callbacks_spec.rb.tt +7 -0
  23. data/lib/rails/generators/test_unit/callbacks/callbacks_generator.rb +13 -0
  24. data/lib/rails/generators/test_unit/callbacks/templates/callbacks_test.rb.tt +9 -0
  25. data/lib/rails/generators/test_unit/collection/collection_generator.rb +13 -0
  26. data/lib/rails/generators/test_unit/collection/templates/collection_test.rb.tt +10 -0
  27. data/spec/acceptance/aql_spec.rb +0 -12
  28. data/spec/acceptance/basic_spec.rb +16 -25
  29. data/spec/acceptance/callbacks_spec.rb +181 -0
  30. data/spec/acceptance/config/guacamole.yml +1 -1
  31. data/spec/acceptance/spec_helper.rb +24 -6
  32. data/spec/fabricators/article.rb +12 -0
  33. data/spec/fabricators/comment.rb +7 -0
  34. data/spec/fabricators/pony.rb +6 -4
  35. data/spec/fabricators/pony_fabricator.rb +7 -0
  36. data/spec/spec_helper.rb +5 -4
  37. data/spec/support/guacamole.yml.erb +5 -0
  38. data/spec/unit/callbacks_spec.rb +139 -0
  39. data/spec/unit/collection_spec.rb +85 -66
  40. data/spec/unit/configuration_spec.rb +165 -21
  41. data/spec/unit/identiy_map_spec.rb +2 -2
  42. data/spec/unit/model_spec.rb +36 -3
  43. metadata +181 -12
  44. data/Gemfile.devtools +0 -67
  45. data/config/devtools.yml +0 -4
  46. data/config/flay.yml +0 -3
  47. data/config/flog.yml +0 -2
  48. data/config/mutant.yml +0 -3
  49. data/config/yardstick.yml +0 -2
  50. data/tasks/adjustments.rake +0 -34
data/config/devtools.yml DELETED
@@ -1,4 +0,0 @@
1
- ---
2
- unit_test_timeout: 0.1
3
- fail_on_branch:
4
- - "master"
data/config/flay.yml DELETED
@@ -1,3 +0,0 @@
1
- ---
2
- threshold: 7
3
- total_score: 74
data/config/flog.yml DELETED
@@ -1,2 +0,0 @@
1
- ---
2
- threshold: 0
data/config/mutant.yml DELETED
@@ -1,3 +0,0 @@
1
- ---
2
- name: guacamole
3
- namespace: Guacamole
data/config/yardstick.yml DELETED
@@ -1,2 +0,0 @@
1
- ---
2
- threshold: 100
@@ -1,34 +0,0 @@
1
- # -*- encoding : utf-8 -*-
2
- ## Specs
3
- # Difference to Devtools:
4
- # * Acceptance, no integration tests
5
-
6
- Rake::Task['spec'].clear
7
- Rake::Task['spec:integration'].clear
8
-
9
- desc 'Run all specs'
10
- task spec: %w[ spec:unit spec:acceptance ]
11
-
12
- namespace :spec do
13
- desc 'Run the acceptance tests. Requires ArangoDB to be running.'
14
- RSpec::Core::RakeTask.new(:acceptance) do |spec|
15
- spec.pattern = 'spec/acceptance/*_spec.rb'
16
- end
17
- end
18
-
19
- ## CI Task
20
- # Differences to Devtools:
21
- # * Only run specific tasks
22
-
23
- Rake::Task['ci'].clear
24
-
25
- desc 'Run all metrics and specs'
26
- task ci: %w[
27
- spec
28
- metrics:coverage
29
- metrics:reek
30
- metrics:yardstick:verify
31
- ]
32
-
33
- ## Default Task
34
- task default: :ci