push_type_core 0.8.0.beta.2 → 0.8.0.beta.3

Sign up to get free protection for your applications and to get access to all the features.
Files changed (23) hide show
  1. checksums.yaml +4 -4
  2. data/app/fields/push_type/asset_field.rb +1 -1
  3. data/app/fields/push_type/relation_field.rb +1 -1
  4. data/lib/push_type/version.rb +1 -1
  5. data/test/dummy/config/initializers/push_type.rb +1 -1
  6. data/test/dummy/config/secrets.yml +2 -2
  7. data/test/dummy/db/schema.rb +1 -1
  8. data/test/dummy/log/test.log +8647 -8613
  9. data/test/dummy/tmp/cache/assets/test/sprockets/v3.0/0ANSDcZJu9gPyqtYPIW729qm1kriQ29Vn9LU8T2SGQU.cache +0 -0
  10. data/test/dummy/tmp/cache/assets/test/sprockets/v3.0/_d65qW7wxRtKVSYpmfSenECz5QUWVI9pppUgV7TA1Rk.cache +0 -0
  11. data/test/dummy/tmp/generators/app/models/location.rb +7 -0
  12. data/test/fields/push_type/asset_field_test.rb +8 -0
  13. data/test/fields/push_type/relation_field_test.rb +1 -1
  14. metadata +20 -20
  15. data/test/dummy/tmp/generators/app/presenters/page_presenter.rb +0 -12
  16. /data/test/dummy/db/migrate/{20160215150602_create_push_type_users.push_type.rb → 20160219133942_create_push_type_users.push_type.rb} +0 -0
  17. /data/test/dummy/db/migrate/{20160215150603_create_push_type_nodes.push_type.rb → 20160219133943_create_push_type_nodes.push_type.rb} +0 -0
  18. /data/test/dummy/db/migrate/{20160215150604_create_push_type_node_hierarchies.push_type.rb → 20160219133944_create_push_type_node_hierarchies.push_type.rb} +0 -0
  19. /data/test/dummy/db/migrate/{20160215150605_create_push_type_assets.push_type.rb → 20160219133945_create_push_type_assets.push_type.rb} +0 -0
  20. /data/test/dummy/db/migrate/{20160215150606_add_field_store_default_values.push_type.rb → 20160219133946_add_field_store_default_values.push_type.rb} +0 -0
  21. /data/test/dummy/db/migrate/{20160215150607_drop_legacy_push_type_taxonomies.push_type.rb → 20160219133947_drop_legacy_push_type_taxonomies.push_type.rb} +0 -0
  22. /data/test/dummy/tmp/cache/assets/test/sprockets/v3.0/{HbQzCpEE_QUF4m04TN_zIYyaX1ZCcx171j2td0cH-Vk.cache → 2FQF7uxsHizgSoGRwbNmDmFTPoWfdOsi-4mptjRhClE.cache} +0 -0
  23. /data/test/dummy/tmp/cache/assets/test/sprockets/v3.0/{BbdqmNmo_cMpT3dnntuUSQnMCU3FOU0qEbTy3ESfBHE.cache → oQZIWFGqjXT0crXajNxkE6c5otWSMfx0ji4kIN6v3XM.cache} +0 -0
@@ -0,0 +1,7 @@
1
+ class Location < PushType::Structure
2
+
3
+ # Model the content by adding custom fields to the structure.
4
+ field :foo, :string
5
+ field :bar, :text
6
+
7
+ end
@@ -19,5 +19,13 @@ module PushType
19
19
  it { node.foo_id.must_equal asset.id }
20
20
  it { node.foo.must_equal asset }
21
21
 
22
+ describe 'with missing relations' do
23
+ before do
24
+ asset.destroy
25
+ end
26
+
27
+ it { node.foo.must_equal nil }
28
+ end
29
+
22
30
  end
23
31
  end
@@ -62,7 +62,7 @@ module PushType
62
62
  @bars.first.destroy
63
63
  end
64
64
 
65
- it { proc { node.page }.must_raise ActiveRecord::RecordNotFound }
65
+ it { node.page.must_equal nil }
66
66
  it { node.bars.size.must_equal 1 }
67
67
  end
68
68
 
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: push_type_core
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.8.0.beta.2
4
+ version: 0.8.0.beta.3
5
5
  platform: ruby
6
6
  authors:
7
7
  - Aaron Russell
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2016-02-15 00:00:00.000000000 Z
11
+ date: 2016-02-19 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rails
@@ -256,12 +256,12 @@ files:
256
256
  - test/dummy/config/locales/en.yml
257
257
  - test/dummy/config/routes.rb
258
258
  - test/dummy/config/secrets.yml
259
- - test/dummy/db/migrate/20160215150602_create_push_type_users.push_type.rb
260
- - test/dummy/db/migrate/20160215150603_create_push_type_nodes.push_type.rb
261
- - test/dummy/db/migrate/20160215150604_create_push_type_node_hierarchies.push_type.rb
262
- - test/dummy/db/migrate/20160215150605_create_push_type_assets.push_type.rb
263
- - test/dummy/db/migrate/20160215150606_add_field_store_default_values.push_type.rb
264
- - test/dummy/db/migrate/20160215150607_drop_legacy_push_type_taxonomies.push_type.rb
259
+ - test/dummy/db/migrate/20160219133942_create_push_type_users.push_type.rb
260
+ - test/dummy/db/migrate/20160219133943_create_push_type_nodes.push_type.rb
261
+ - test/dummy/db/migrate/20160219133944_create_push_type_node_hierarchies.push_type.rb
262
+ - test/dummy/db/migrate/20160219133945_create_push_type_assets.push_type.rb
263
+ - test/dummy/db/migrate/20160219133946_add_field_store_default_values.push_type.rb
264
+ - test/dummy/db/migrate/20160219133947_drop_legacy_push_type_taxonomies.push_type.rb
265
265
  - test/dummy/db/schema.rb
266
266
  - test/dummy/db/seeds.rb
267
267
  - test/dummy/log/test.log
@@ -271,14 +271,14 @@ files:
271
271
  - test/dummy/public/favicon.ico
272
272
  - test/dummy/public/robots.txt
273
273
  - test/dummy/tmp/cache/assets/test/sprockets/v3.0/0ANSDcZJu9gPyqtYPIW729qm1kriQ29Vn9LU8T2SGQU.cache
274
+ - test/dummy/tmp/cache/assets/test/sprockets/v3.0/2FQF7uxsHizgSoGRwbNmDmFTPoWfdOsi-4mptjRhClE.cache
274
275
  - test/dummy/tmp/cache/assets/test/sprockets/v3.0/3T6ioyhwSsEzte_a9viHBvfmuKgORQ019srIEoUYkVs.cache
275
276
  - test/dummy/tmp/cache/assets/test/sprockets/v3.0/5Lly_CA8DZvPhQV2jDQx-Y6P_y3Ygra9t5jfSlGhHDA.cache
276
- - test/dummy/tmp/cache/assets/test/sprockets/v3.0/BbdqmNmo_cMpT3dnntuUSQnMCU3FOU0qEbTy3ESfBHE.cache
277
- - test/dummy/tmp/cache/assets/test/sprockets/v3.0/HbQzCpEE_QUF4m04TN_zIYyaX1ZCcx171j2td0cH-Vk.cache
278
277
  - test/dummy/tmp/cache/assets/test/sprockets/v3.0/IYzwMwq7DWWSuojH6oXsrP__pcD7O8TQieMFSzQiwnc.cache
279
278
  - test/dummy/tmp/cache/assets/test/sprockets/v3.0/OI6uxGcnsKavdWTtwDAasU3wPx8QXhzBgV0X2n1KjMQ.cache
280
279
  - test/dummy/tmp/cache/assets/test/sprockets/v3.0/_d65qW7wxRtKVSYpmfSenECz5QUWVI9pppUgV7TA1Rk.cache
281
- - test/dummy/tmp/generators/app/presenters/page_presenter.rb
280
+ - test/dummy/tmp/cache/assets/test/sprockets/v3.0/oQZIWFGqjXT0crXajNxkE6c5otWSMfx0ji4kIN6v3XM.cache
281
+ - test/dummy/tmp/generators/app/models/location.rb
282
282
  - test/fields/push_type/asset_field_test.rb
283
283
  - test/fields/push_type/boolean_field_test.rb
284
284
  - test/fields/push_type/date_field_test.rb
@@ -382,12 +382,12 @@ test_files:
382
382
  - test/dummy/config/routes.rb
383
383
  - test/dummy/config/secrets.yml
384
384
  - test/dummy/config.ru
385
- - test/dummy/db/migrate/20160215150602_create_push_type_users.push_type.rb
386
- - test/dummy/db/migrate/20160215150603_create_push_type_nodes.push_type.rb
387
- - test/dummy/db/migrate/20160215150604_create_push_type_node_hierarchies.push_type.rb
388
- - test/dummy/db/migrate/20160215150605_create_push_type_assets.push_type.rb
389
- - test/dummy/db/migrate/20160215150606_add_field_store_default_values.push_type.rb
390
- - test/dummy/db/migrate/20160215150607_drop_legacy_push_type_taxonomies.push_type.rb
385
+ - test/dummy/db/migrate/20160219133942_create_push_type_users.push_type.rb
386
+ - test/dummy/db/migrate/20160219133943_create_push_type_nodes.push_type.rb
387
+ - test/dummy/db/migrate/20160219133944_create_push_type_node_hierarchies.push_type.rb
388
+ - test/dummy/db/migrate/20160219133945_create_push_type_assets.push_type.rb
389
+ - test/dummy/db/migrate/20160219133946_add_field_store_default_values.push_type.rb
390
+ - test/dummy/db/migrate/20160219133947_drop_legacy_push_type_taxonomies.push_type.rb
391
391
  - test/dummy/db/schema.rb
392
392
  - test/dummy/db/seeds.rb
393
393
  - test/dummy/log/test.log
@@ -399,14 +399,14 @@ test_files:
399
399
  - test/dummy/Rakefile
400
400
  - test/dummy/README.rdoc
401
401
  - test/dummy/tmp/cache/assets/test/sprockets/v3.0/0ANSDcZJu9gPyqtYPIW729qm1kriQ29Vn9LU8T2SGQU.cache
402
+ - test/dummy/tmp/cache/assets/test/sprockets/v3.0/2FQF7uxsHizgSoGRwbNmDmFTPoWfdOsi-4mptjRhClE.cache
402
403
  - test/dummy/tmp/cache/assets/test/sprockets/v3.0/3T6ioyhwSsEzte_a9viHBvfmuKgORQ019srIEoUYkVs.cache
403
404
  - test/dummy/tmp/cache/assets/test/sprockets/v3.0/5Lly_CA8DZvPhQV2jDQx-Y6P_y3Ygra9t5jfSlGhHDA.cache
404
405
  - test/dummy/tmp/cache/assets/test/sprockets/v3.0/_d65qW7wxRtKVSYpmfSenECz5QUWVI9pppUgV7TA1Rk.cache
405
- - test/dummy/tmp/cache/assets/test/sprockets/v3.0/BbdqmNmo_cMpT3dnntuUSQnMCU3FOU0qEbTy3ESfBHE.cache
406
- - test/dummy/tmp/cache/assets/test/sprockets/v3.0/HbQzCpEE_QUF4m04TN_zIYyaX1ZCcx171j2td0cH-Vk.cache
407
406
  - test/dummy/tmp/cache/assets/test/sprockets/v3.0/IYzwMwq7DWWSuojH6oXsrP__pcD7O8TQieMFSzQiwnc.cache
408
407
  - test/dummy/tmp/cache/assets/test/sprockets/v3.0/OI6uxGcnsKavdWTtwDAasU3wPx8QXhzBgV0X2n1KjMQ.cache
409
- - test/dummy/tmp/generators/app/presenters/page_presenter.rb
408
+ - test/dummy/tmp/cache/assets/test/sprockets/v3.0/oQZIWFGqjXT0crXajNxkE6c5otWSMfx0ji4kIN6v3XM.cache
409
+ - test/dummy/tmp/generators/app/models/location.rb
410
410
  - test/fields/push_type/asset_field_test.rb
411
411
  - test/fields/push_type/boolean_field_test.rb
412
412
  - test/fields/push_type/date_field_test.rb
@@ -1,12 +0,0 @@
1
- class PagePresenter < PushType::Presenter
2
-
3
- # This class delegates to the model, Page
4
- # Override any methods to add custom presentation logic
5
- # View helpers are accessible from the `h` method
6
-
7
- # Example:
8
- # def title
9
- # h.content_tag :strong, super()
10
- # end
11
-
12
- end