publishing_logic 0.2.0 → 0.3.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (41) hide show
  1. checksums.yaml +7 -0
  2. data/.document +1 -1
  3. data/.gitignore +9 -23
  4. data/.rspec +2 -0
  5. data/.specification.example +34 -34
  6. data/.travis.yml +4 -0
  7. data/CODE_OF_CONDUCT.md +49 -0
  8. data/Gemfile +4 -0
  9. data/LICENSE +1 -1
  10. data/README.md +65 -0
  11. data/Rakefile +3 -49
  12. data/bin/console +14 -0
  13. data/bin/setup +8 -0
  14. data/lib/generators/publishing_logic/fields_generator.rb +13 -0
  15. data/lib/generators/publishing_logic/templates/migration.erb +10 -0
  16. data/lib/locale/en.yml +9 -0
  17. data/lib/locale/hu.yml +9 -0
  18. data/lib/publishing_logic.rb +7 -1
  19. data/lib/publishing_logic/model_logic.rb +51 -0
  20. data/lib/publishing_logic/version.rb +3 -0
  21. data/publishing_logic.gemspec +29 -0
  22. metadata +114 -176
  23. data/README.rdoc +0 -29
  24. data/VERSION +0 -1
  25. data/lib/model_logic.rb +0 -82
  26. data/rails_generators/publishing_logic_fields/USAGE +0 -2
  27. data/rails_generators/publishing_logic_fields/publishing_logic_fields_generator.rb +0 -34
  28. data/rails_generators/publishing_logic_fields/templates/app/views/publishing_logic_fields.html.erb +0 -12
  29. data/rails_generators/publishing_logic_fields/templates/db/migrate/add_publishing_logic_fields.rb.erb +0 -18
  30. data/spec/general_model_logic.rb +0 -93
  31. data/spec/models_with_all_fields_spec.rb +0 -85
  32. data/spec/models_with_no_published_until_field_spec.rb +0 -68
  33. data/spec/spec.opts +0 -1
  34. data/spec/spec_helper.rb +0 -55
  35. data/spec/support/database_cleanliness.rb +0 -14
  36. data/spec/support/database_connection.rb +0 -4
  37. data/spec/support/database_migrations.rb +0 -56
  38. data/spec/support/factories.rb +0 -10
  39. data/spec/support/logging.rb +0 -2
  40. data/spec/support/models/article.rb +0 -3
  41. data/spec/support/models/programme.rb +0 -3
@@ -1,10 +0,0 @@
1
- Factory.define :programme do |p|
2
- p.publishing_enabled { true }
3
- p.published_at { Date.yesterday }
4
- p.published_until { Date.tomorrow }
5
- end
6
-
7
- Factory.define :article do |p|
8
- p.publishing_enabled { true }
9
- p.published_at { Date.yesterday }
10
- end
@@ -1,2 +0,0 @@
1
- require 'logger'
2
- ActiveRecord::Base.logger = Logger.new("test.log")
@@ -1,3 +0,0 @@
1
- class Article < ActiveRecord::Base
2
- include PublishingLogic::ModelLogic
3
- end
@@ -1,3 +0,0 @@
1
- class Programme < ActiveRecord::Base
2
- include PublishingLogic::ModelLogic
3
- end