aasm 4.12.3 → 5.5.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (218) hide show
  1. checksums.yaml +5 -5
  2. data/README.md +284 -119
  3. data/lib/aasm/aasm.rb +30 -27
  4. data/lib/aasm/base.rb +61 -11
  5. data/lib/aasm/configuration.rb +3 -0
  6. data/lib/aasm/core/event.rb +26 -30
  7. data/lib/aasm/core/invoker.rb +129 -0
  8. data/lib/aasm/core/invokers/base_invoker.rb +75 -0
  9. data/lib/aasm/core/invokers/class_invoker.rb +52 -0
  10. data/lib/aasm/core/invokers/literal_invoker.rb +49 -0
  11. data/lib/aasm/core/invokers/proc_invoker.rb +59 -0
  12. data/lib/aasm/core/state.rb +16 -14
  13. data/lib/aasm/core/transition.rb +8 -69
  14. data/lib/aasm/dsl_helper.rb +24 -22
  15. data/lib/aasm/errors.rb +5 -3
  16. data/lib/aasm/instance_base.rb +28 -5
  17. data/lib/aasm/localizer.rb +13 -3
  18. data/lib/aasm/persistence/active_record_persistence.rb +25 -5
  19. data/lib/aasm/persistence/base.rb +14 -3
  20. data/lib/aasm/persistence/core_data_query_persistence.rb +2 -1
  21. data/lib/aasm/persistence/dynamoid_persistence.rb +1 -1
  22. data/lib/aasm/persistence/mongoid_persistence.rb +1 -1
  23. data/lib/aasm/persistence/no_brainer_persistence.rb +105 -0
  24. data/lib/aasm/persistence/orm.rb +23 -19
  25. data/lib/aasm/persistence/plain_persistence.rb +2 -1
  26. data/lib/aasm/persistence/redis_persistence.rb +1 -1
  27. data/lib/aasm/persistence/sequel_persistence.rb +0 -1
  28. data/lib/aasm/persistence.rb +3 -0
  29. data/lib/aasm/rspec/allow_event.rb +5 -1
  30. data/lib/aasm/rspec/allow_transition_to.rb +5 -1
  31. data/lib/aasm/rspec/transition_from.rb +5 -1
  32. data/lib/aasm/version.rb +1 -1
  33. data/lib/aasm.rb +5 -2
  34. data/lib/generators/aasm/orm_helpers.rb +7 -1
  35. data/lib/generators/active_record/aasm_generator.rb +3 -1
  36. data/lib/generators/active_record/templates/migration.rb +1 -1
  37. data/lib/generators/nobrainer/aasm_generator.rb +28 -0
  38. data/lib/motion-aasm.rb +1 -0
  39. metadata +42 -344
  40. data/.document +0 -6
  41. data/.gitignore +0 -20
  42. data/.travis.yml +0 -52
  43. data/API +0 -34
  44. data/Appraisals +0 -43
  45. data/CHANGELOG.md +0 -370
  46. data/CODE_OF_CONDUCT.md +0 -13
  47. data/CONTRIBUTING.md +0 -24
  48. data/Gemfile +0 -7
  49. data/Gemfile.lock_old +0 -151
  50. data/HOWTO +0 -12
  51. data/PLANNED_CHANGES.md +0 -11
  52. data/README_FROM_VERSION_3_TO_4.md +0 -240
  53. data/Rakefile +0 -31
  54. data/TESTING.md +0 -25
  55. data/aasm.gemspec +0 -35
  56. data/callbacks.txt +0 -51
  57. data/gemfiles/rails_3.2.gemfile +0 -13
  58. data/gemfiles/rails_4.0.gemfile +0 -15
  59. data/gemfiles/rails_4.2.gemfile +0 -16
  60. data/gemfiles/rails_4.2_mongoid_5.gemfile +0 -11
  61. data/gemfiles/rails_5.0.gemfile +0 -14
  62. data/spec/database.rb +0 -44
  63. data/spec/database.yml +0 -3
  64. data/spec/en.yml +0 -12
  65. data/spec/en_deprecated_style.yml +0 -10
  66. data/spec/generators/active_record_generator_spec.rb +0 -47
  67. data/spec/generators/mongoid_generator_spec.rb +0 -31
  68. data/spec/models/active_record/basic_active_record_two_state_machines_example.rb +0 -25
  69. data/spec/models/active_record/complex_active_record_example.rb +0 -37
  70. data/spec/models/active_record/derivate_new_dsl.rb +0 -7
  71. data/spec/models/active_record/false_state.rb +0 -35
  72. data/spec/models/active_record/gate.rb +0 -39
  73. data/spec/models/active_record/invalid_persistor.rb +0 -29
  74. data/spec/models/active_record/localizer_test_model.rb +0 -34
  75. data/spec/models/active_record/no_direct_assignment.rb +0 -21
  76. data/spec/models/active_record/no_scope.rb +0 -21
  77. data/spec/models/active_record/persisted_state.rb +0 -12
  78. data/spec/models/active_record/provided_and_persisted_state.rb +0 -24
  79. data/spec/models/active_record/reader.rb +0 -7
  80. data/spec/models/active_record/readme_job.rb +0 -21
  81. data/spec/models/active_record/silent_persistor.rb +0 -29
  82. data/spec/models/active_record/simple_new_dsl.rb +0 -17
  83. data/spec/models/active_record/thief.rb +0 -29
  84. data/spec/models/active_record/transactor.rb +0 -124
  85. data/spec/models/active_record/transient.rb +0 -6
  86. data/spec/models/active_record/validator.rb +0 -118
  87. data/spec/models/active_record/with_enum.rb +0 -39
  88. data/spec/models/active_record/with_enum_without_column.rb +0 -38
  89. data/spec/models/active_record/with_false_enum.rb +0 -31
  90. data/spec/models/active_record/with_true_enum.rb +0 -39
  91. data/spec/models/active_record/worker.rb +0 -2
  92. data/spec/models/active_record/writer.rb +0 -6
  93. data/spec/models/basic_two_state_machines_example.rb +0 -25
  94. data/spec/models/callbacks/basic.rb +0 -98
  95. data/spec/models/callbacks/basic_multiple.rb +0 -75
  96. data/spec/models/callbacks/guard_within_block.rb +0 -67
  97. data/spec/models/callbacks/guard_within_block_multiple.rb +0 -66
  98. data/spec/models/callbacks/multiple_transitions_transition_guard.rb +0 -66
  99. data/spec/models/callbacks/multiple_transitions_transition_guard_multiple.rb +0 -65
  100. data/spec/models/callbacks/private_method.rb +0 -44
  101. data/spec/models/callbacks/private_method_multiple.rb +0 -44
  102. data/spec/models/callbacks/with_args.rb +0 -62
  103. data/spec/models/callbacks/with_args_multiple.rb +0 -61
  104. data/spec/models/callbacks/with_state_arg.rb +0 -30
  105. data/spec/models/callbacks/with_state_arg_multiple.rb +0 -26
  106. data/spec/models/complex_example.rb +0 -222
  107. data/spec/models/conversation.rb +0 -93
  108. data/spec/models/default_state.rb +0 -12
  109. data/spec/models/double_definer.rb +0 -21
  110. data/spec/models/dynamoid/complex_dynamoid_example.rb +0 -37
  111. data/spec/models/dynamoid/dynamoid_multiple.rb +0 -18
  112. data/spec/models/dynamoid/dynamoid_simple.rb +0 -18
  113. data/spec/models/foo.rb +0 -106
  114. data/spec/models/foo_callback_multiple.rb +0 -45
  115. data/spec/models/guard_arguments_check.rb +0 -17
  116. data/spec/models/guard_with_params.rb +0 -24
  117. data/spec/models/guard_with_params_multiple.rb +0 -18
  118. data/spec/models/guardian.rb +0 -58
  119. data/spec/models/guardian_multiple.rb +0 -48
  120. data/spec/models/guardian_without_from_specified.rb +0 -18
  121. data/spec/models/initial_state_proc.rb +0 -31
  122. data/spec/models/mongoid/complex_mongoid_example.rb +0 -37
  123. data/spec/models/mongoid/invalid_persistor_mongoid.rb +0 -39
  124. data/spec/models/mongoid/mongoid_relationships.rb +0 -26
  125. data/spec/models/mongoid/no_scope_mongoid.rb +0 -21
  126. data/spec/models/mongoid/silent_persistor_mongoid.rb +0 -39
  127. data/spec/models/mongoid/simple_mongoid.rb +0 -23
  128. data/spec/models/mongoid/simple_new_dsl_mongoid.rb +0 -25
  129. data/spec/models/mongoid/validator_mongoid.rb +0 -100
  130. data/spec/models/multi_transitioner.rb +0 -34
  131. data/spec/models/multiple_transitions_that_differ_only_by_guard.rb +0 -31
  132. data/spec/models/namespaced_multiple_example.rb +0 -42
  133. data/spec/models/no_initial_state.rb +0 -25
  134. data/spec/models/not_auto_loaded/process.rb +0 -21
  135. data/spec/models/parametrised_event.rb +0 -42
  136. data/spec/models/parametrised_event_multiple.rb +0 -29
  137. data/spec/models/process_with_new_dsl.rb +0 -31
  138. data/spec/models/provided_state.rb +0 -24
  139. data/spec/models/redis/complex_redis_example.rb +0 -40
  140. data/spec/models/redis/redis_multiple.rb +0 -20
  141. data/spec/models/redis/redis_simple.rb +0 -20
  142. data/spec/models/sequel/complex_sequel_example.rb +0 -46
  143. data/spec/models/sequel/invalid_persistor.rb +0 -52
  144. data/spec/models/sequel/sequel_multiple.rb +0 -25
  145. data/spec/models/sequel/sequel_simple.rb +0 -26
  146. data/spec/models/sequel/silent_persistor.rb +0 -50
  147. data/spec/models/sequel/transactor.rb +0 -112
  148. data/spec/models/sequel/validator.rb +0 -93
  149. data/spec/models/sequel/worker.rb +0 -12
  150. data/spec/models/silencer.rb +0 -27
  151. data/spec/models/simple_custom_example.rb +0 -53
  152. data/spec/models/simple_example.rb +0 -15
  153. data/spec/models/simple_multiple_example.rb +0 -42
  154. data/spec/models/state_machine_with_failed_event.rb +0 -20
  155. data/spec/models/states_on_one_line_example.rb +0 -8
  156. data/spec/models/sub_class.rb +0 -41
  157. data/spec/models/sub_class_with_more_states.rb +0 -18
  158. data/spec/models/sub_classing.rb +0 -3
  159. data/spec/models/super_class.rb +0 -46
  160. data/spec/models/this_name_better_not_be_in_use.rb +0 -11
  161. data/spec/models/valid_state_name.rb +0 -23
  162. data/spec/spec_helper.rb +0 -26
  163. data/spec/spec_helpers/active_record.rb +0 -7
  164. data/spec/spec_helpers/dynamoid.rb +0 -33
  165. data/spec/spec_helpers/mongoid.rb +0 -7
  166. data/spec/spec_helpers/redis.rb +0 -15
  167. data/spec/spec_helpers/remove_warnings.rb +0 -1
  168. data/spec/spec_helpers/sequel.rb +0 -7
  169. data/spec/unit/api_spec.rb +0 -100
  170. data/spec/unit/basic_two_state_machines_example_spec.rb +0 -10
  171. data/spec/unit/callback_multiple_spec.rb +0 -300
  172. data/spec/unit/callbacks_spec.rb +0 -491
  173. data/spec/unit/complex_example_spec.rb +0 -94
  174. data/spec/unit/complex_multiple_example_spec.rb +0 -115
  175. data/spec/unit/edge_cases_spec.rb +0 -16
  176. data/spec/unit/event_multiple_spec.rb +0 -73
  177. data/spec/unit/event_naming_spec.rb +0 -16
  178. data/spec/unit/event_spec.rb +0 -381
  179. data/spec/unit/exception_spec.rb +0 -11
  180. data/spec/unit/guard_arguments_check_spec.rb +0 -9
  181. data/spec/unit/guard_multiple_spec.rb +0 -60
  182. data/spec/unit/guard_spec.rb +0 -89
  183. data/spec/unit/guard_with_params_multiple_spec.rb +0 -10
  184. data/spec/unit/guard_with_params_spec.rb +0 -14
  185. data/spec/unit/guard_without_from_specified_spec.rb +0 -10
  186. data/spec/unit/initial_state_multiple_spec.rb +0 -15
  187. data/spec/unit/initial_state_spec.rb +0 -12
  188. data/spec/unit/inspection_multiple_spec.rb +0 -201
  189. data/spec/unit/inspection_spec.rb +0 -149
  190. data/spec/unit/localizer_spec.rb +0 -78
  191. data/spec/unit/memory_leak_spec.rb +0 -38
  192. data/spec/unit/multiple_transitions_that_differ_only_by_guard_spec.rb +0 -14
  193. data/spec/unit/namespaced_multiple_example_spec.rb +0 -75
  194. data/spec/unit/new_dsl_spec.rb +0 -12
  195. data/spec/unit/override_warning_spec.rb +0 -94
  196. data/spec/unit/persistence/active_record_persistence_multiple_spec.rb +0 -618
  197. data/spec/unit/persistence/active_record_persistence_spec.rb +0 -735
  198. data/spec/unit/persistence/dynamoid_persistence_multiple_spec.rb +0 -135
  199. data/spec/unit/persistence/dynamoid_persistence_spec.rb +0 -84
  200. data/spec/unit/persistence/mongoid_persistence_multiple_spec.rb +0 -204
  201. data/spec/unit/persistence/mongoid_persistence_spec.rb +0 -169
  202. data/spec/unit/persistence/redis_persistence_multiple_spec.rb +0 -88
  203. data/spec/unit/persistence/redis_persistence_spec.rb +0 -53
  204. data/spec/unit/persistence/sequel_persistence_multiple_spec.rb +0 -148
  205. data/spec/unit/persistence/sequel_persistence_spec.rb +0 -368
  206. data/spec/unit/readme_spec.rb +0 -41
  207. data/spec/unit/reloading_spec.rb +0 -15
  208. data/spec/unit/rspec_matcher_spec.rb +0 -79
  209. data/spec/unit/simple_custom_example_spec.rb +0 -39
  210. data/spec/unit/simple_example_spec.rb +0 -42
  211. data/spec/unit/simple_multiple_example_spec.rb +0 -91
  212. data/spec/unit/state_spec.rb +0 -89
  213. data/spec/unit/states_on_one_line_example_spec.rb +0 -16
  214. data/spec/unit/subclassing_multiple_spec.rb +0 -74
  215. data/spec/unit/subclassing_spec.rb +0 -46
  216. data/spec/unit/transition_spec.rb +0 -436
  217. data/test/minitest_helper.rb +0 -57
  218. data/test/unit/minitest_matcher_test.rb +0 -80
data/.travis.yml DELETED
@@ -1,52 +0,0 @@
1
- sudo: false
2
- language: ruby
3
- cache: bundler
4
-
5
- rvm:
6
- - 1.9.3
7
- - 2.2.6
8
- - 2.3.3
9
- - jruby-1.7 # JRuby in 1.9 mode
10
- - jruby-9.0.5.0
11
-
12
- services:
13
- - mongodb
14
- - redis-server
15
-
16
- gemfile:
17
- - gemfiles/rails_3.2.gemfile
18
- - gemfiles/rails_4.0.gemfile
19
- - gemfiles/rails_4.2.gemfile
20
- - gemfiles/rails_4.2_mongoid_5.gemfile
21
- - gemfiles/rails_5.0.gemfile
22
-
23
- before_script:
24
- - mkdir /tmp/dynamodb
25
- - wget -O - https://s3-ap-southeast-1.amazonaws.com/dynamodb-local-singapore/dynamodb_local_latest.tar.gz | tar xz --directory /tmp/dynamodb
26
- - java -Djava.library.path=/tmp/dynamodb/DynamoDBLocal_lib -jar /tmp/dynamodb/DynamoDBLocal.jar -inMemory -delayTransientStatuses -port 30180 &
27
- - mongod --version
28
-
29
- script:
30
- - bundle exec rspec spec
31
- - bundle exec rake test
32
-
33
- matrix:
34
- exclude:
35
- - rvm: 1.9.3
36
- gemfile: gemfiles/rails_4.2_mongoid_5.gemfile
37
- - rvm: 1.9.3
38
- gemfile: gemfiles/rails_5.0.gemfile
39
- - rvm: 2.2.6
40
- gemfile: gemfiles/rails_3.2.gemfile
41
- - rvm: 2.3.3
42
- gemfile: gemfiles/rails_3.2.gemfile
43
- - rvm: jruby-1.7
44
- gemfile: gemfiles/rails_4.2_mongoid_5.gemfile
45
- - rvm: jruby-1.7
46
- gemfile: gemfiles/rails_5.0.gemfile
47
- - rvm: jruby-9.0.5.0
48
- gemfile: gemfiles/rails_5.0.gemfile
49
-
50
- notifications:
51
- slack:
52
- secure: gpltVWntdKz0nSE6A5UvuX4qbN35uW51nsW+Ojgqm8Qsv8K240/NlZRYutFHr7GnJTe0rEEP2Oy3ZBnBtZKFn13RlTEAU/FCAxebr4H24rr29Ypwwp5xjiSE4MuoBEnroo4lw6ka3LsJnrY2PKRMiLJGsS0WsEPY4x8NUG/vyY8=
data/API DELETED
@@ -1,34 +0,0 @@
1
-
2
- Overwrite method to read the current state. Used to provide another storage mechanism,
3
- different from the standard Rails read_attribute method.
4
-
5
- class MyClass
6
- include AASM
7
-
8
- def aasm_read_state
9
- # retrieve the current state manually
10
- end
11
- end
12
-
13
-
14
- Overwrite method to write the current state (and actually persist it). Used to provide
15
- another storage mechanism, different from the standard Rails write_attribute method.
16
-
17
- class MyClass
18
- include AASM
19
-
20
- def aasm_write_state
21
- # store and persist the current state manually
22
- end
23
- end
24
-
25
-
26
- Overwrite method to write the current state (without persisting it).
27
-
28
- class MyClass
29
- include AASM
30
-
31
- def aasm_write_state_without_persistence
32
- # store the current state manually
33
- end
34
- end
data/Appraisals DELETED
@@ -1,43 +0,0 @@
1
- appraise 'rails_3.2' do
2
- gem 'rails', '~>3.2.22'
3
- gem 'mongoid', '~>3.1'
4
- gem 'sequel'
5
- gem 'bson_ext', :platforms => :ruby
6
- gem 'test-unit', '~> 3.0'
7
- end
8
-
9
- appraise 'rails_4.0' do
10
- gem 'mime-types', '~> 2', :platforms => [:ruby_19, :jruby]
11
- gem 'rails', '4.0.13'
12
- gem 'mongoid', '~>4.0'
13
- gem 'sequel'
14
- gem 'dynamoid', '~> 1', :platforms => :ruby
15
- gem 'aws-sdk', '~>2', :platforms => :ruby
16
- gem 'redis-objects'
17
- end
18
-
19
- appraise 'rails_4.2' do
20
- gem 'nokogiri', '1.6.8.1', :platforms => [:ruby_19]
21
- gem 'mime-types', '~> 2', :platforms => [:ruby_19, :jruby]
22
- gem 'rails', '4.2.5'
23
- gem 'mongoid', '~>4.0'
24
- gem 'sequel'
25
- gem 'dynamoid', '~> 1', :platforms => :ruby
26
- gem 'aws-sdk', '~>2', :platforms => :ruby
27
- gem 'redis-objects'
28
- end
29
-
30
- appraise 'rails_4.2_mongoid_5' do
31
- gem 'mime-types', '~> 2', :platforms => [:ruby_19, :jruby]
32
- gem 'rails', '4.2.5'
33
- gem 'mongoid', '~>5.0'
34
- end
35
-
36
- appraise 'rails_5.0' do
37
- gem 'rails', '5.0.0'
38
- gem 'mongoid', '~>6.0'
39
- gem 'sequel'
40
- gem 'dynamoid', '~> 1', :platforms => :ruby
41
- gem 'aws-sdk', '~>2', :platforms => :ruby
42
- gem 'redis-objects'
43
- end
data/CHANGELOG.md DELETED
@@ -1,370 +0,0 @@
1
- # CHANGELOG
2
-
3
- ## unreleased
4
- ## 4.12.3
5
-
6
- * Add to AASM fire(event) and fire!(event) methods [#494](https://github.com/aasm/aasm/pull/494), thanks to [slayer](https://github.com/slayer)
7
- * Add `use_transactions` flag to persist changes to the database even when some error occurs. [#493](https://github.com/aasm/aasm/pull/493), thanks to Peter Lampesberger.
8
-
9
- ## 4.12.2
10
-
11
- * Fix guards parameter [#484](https://github.com/aasm/aasm/pull/484), thanks to [teohm](https://github.com/teohm)
12
- * Make errors more inspectable [#452](https://github.com/aasm/aasm/pull/452), thanks to [flexoid](https://github.com/flexoid)
13
- * Enable Dynamoid for Rails 5 [#483](https://github.com/aasm/aasm/pull/483), thanks to [focusshifter](https://github.com/focusshifter)
14
-
15
- ## 4.12.1
16
-
17
- * DRY-up Mongoid and ActiveRecord Persistence, Add Sequel transactions and locking [#475](https://github.com/aasm/aasm/pull/475), thanks to [@Aryk] (https://github.com/Aryk)
18
- * Add aliases for event methods [#476](https://github.com/aasm/aasm/pull/476), thanks to [@Aryk] (https://github.com/Aryk)
19
- * Support Minitest spec expectations [#387](https://github.com/aasm/aasm/pull/387), thanks to [@faragorn] (https://github.com/faragorn)
20
- ## 4.12.0
21
-
22
- * Fix thread safe issue with concurrent-ruby gem [see [pull-request #422](https://github.com/aasm/aasm/pull/442), thanks to [@reidmorrison](https://github.com/reidmorrison)
23
- * Drop Support for Mongo Mapper [see [pull-request #439](https://github.com/aasm/aasm/pull/439)], thanks to [@reidmorrison](https://github.com/reidmorrison)
24
- * add :binding_event option to event [see [pull-request #438](https://github.com/aasm/aasm/pull/438)], thanks to [@leanhdaovn](https://github.com/leanhdaovn)
25
- * fix: `skip_validation_on_save: true` for default_scope records, [see [pull-request #433](https://github.com/aasm/aasm/pull/433)], thanks to [@larissa](https://github.com/larissa)
26
- * Deep clone state machine during inheritance so that state machines in child classes can be modified (see [pull-request #429](https://github.com/aasm/aasm/pull/429)), thanks to [@reidmorrison](https://github.com/reidmorrison) and [@Tybot204](https://github.com/Tybot204)
27
- * add before_success callback for event (see [pull-request #422](https://github.com/aasm/aasm/pull/422)), thanks to [@timsly ](https://github.com/timsly)
28
- * fix: multiple transitions in a single event with the same to and from states (see [issue #372](https://github.com/aasm/aasm/issues/372) and [issue #362](https://github.com/aasm/aasm/issues/362) for details, fixed with [pull-request #408](https://github.com/aasm/aasm/pull/408), thanks to [@dathanb](https://github.com/dathanb))
29
- * fix: passing nil as a argument to callbacks (see [issue #404](https://github.com/aasm/aasm/issues/404) for details, fixed with [pull-request #406](https://github.com/aasm/aasm/pull/406), thanks to [@yogeshjain999](https://github.com/yogeshjain999))
30
-
31
-
32
- ## 4.11.1
33
-
34
- * fix: generator file name when using custom column name instead of
35
- aasm_state (see [issue #398](https://github.com/aasm/aasm/pull/398) for details,
36
- thanks to [@bastianwegge](https://github.com/bastianwegge))
37
- * fix: Scopes when states are defined as a series of symbols (see [issue #397](https://github.com/aasm/aasm/pull/397) for details, thanks to [@evheny0](https://github.com/evheny0))
38
- * fix: Multiple transition behavior when one of the transitions does not
39
- have a "from" parameter (see [issue #392](https://github.com/aasm/aasm/issues/392) for details)
40
- * fix: permissible states not respecting guard parameters (see [issue #388](https://github.com/aasm/aasm/issues/388)) with [pull-request #389](https://github.com/aasm/aasm/pull/389)
41
-
42
- ## 4.11.0
43
-
44
- * support `logger` configuration (see [issue #370](https://github.com/aasm/aasm/pull/370) for details, thanks to [@HoyaBoya](https://github.com/HoyaBoya))
45
- * support configuration to let bang transitions fail if object is invalid (see [issue #366](https://github.com/aasm/aasm/pull/366) and [issue #262](https://github.com/aasm/aasm/issues/262) for details, thanks to [@Wildebeest](https://github.com/Wildebeest))
46
-
47
-
48
- ## 4.10.1
49
-
50
- * fix: suppress warnings when using ActiveRecord enums feature (see [issue #346](https://github.com/aasm/aasm/pull/346) for details, thanks to [@110y](https://github.com/110y), and [issue #353](https://github.com/aasm/aasm/pull/353) for details, thanks to [@nathanstitt](https://github.com/nathanstitt))
51
- * fix: handle array of success callbacks for transitions properly (see [issue #363](https://github.com/aasm/aasm/pull/363) for details, thanks to [@shunichi](https://github.com/shunichi))
52
- * support `permitted: false` for states and events query/inspection methods (see [issue #364](https://github.com/aasm/aasm/pull/364) for details, thanks to [@hspazio](https://github.com/hspazio))
53
-
54
- ## 4.10.0
55
-
56
- * fix: some issues with RubyMotion (see [issue #320](https://github.com/aasm/aasm/pull/320) and [issue #343](https://github.com/aasm/aasm/pull/343) for details, thanks to [@Infotaku](https://github.com/Infotaku))
57
- * fix: transitions now work in dup'ed copies (see [issue #325](https://github.com/aasm/aasm/pull/325) which fixes [issue #273](https://github.com/aasm/aasm/pull/273) for details, thanks to [@lingceng](https://github.com/lingceng))
58
- * fix: allow skipping the `aasm_ensure_initial_state` callback (see [issue #326](https://github.com/aasm/aasm/pull/326) for details, thanks to [@sineed](https://github.com/sineed))
59
- * fix: has_many association helper works again for Mongoid (see [issue #333](https://github.com/aasm/aasm/pull/333) which fixes [issue #332](https://github.com/aasm/aasm/pull/332) for details, thanks to [@anilmaurya](https://github.com/anilmaurya))
60
- * improve performance / refactor: load and run only code which is needed (see [issue #336](https://github.com/aasm/aasm/pull/336) for details, thanks to [@csmuc](https://github.com/csmuc))
61
- * improve: warn when overriding an existing method (see [issue #340](https://github.com/aasm/aasm/pull/340) which fixes [issue #335](https://github.com/aasm/aasm/pull/335) for details, thanks to [@pirj](https://github.com/pirj))
62
- * fix: correct error message (by not evaluating the current state lazily) (see [issue #341](https://github.com/aasm/aasm/pull/341) which fixes [issue #312](https://github.com/aasm/aasm/pull/312) for details, thanks to [@pirj](https://github.com/pirj))
63
- * addition: support for Redis as persistence layer (see [issue #190](https://github.com/aasm/aasm/pull/190) for details, thanks to [@javajax](https://github.com/javajax))
64
- * addition: support transition `:success` callbacks (see [issue #239](https://github.com/aasm/aasm/pull/239) which fixes [issue #236](https://github.com/aasm/aasm/pull/236) for details, thanks to [@brega](https://github.com/brega))
65
- * addition: support for namespacing methods and state names (see [issue #259](https://github.com/aasm/aasm/pull/259) for details, thanks to [@allspiritseve](https://github.com/allspiritseve))
66
- * addition: support for defining multiple states in one line (see [issue #288](https://github.com/aasm/aasm/pull/288) which fixes [issue #146](https://github.com/aasm/aasm/pull/146) for details, thanks to [@HParker](https://github.com/HParker))
67
- * fix: uninitialised constant when running Rails generator (see [issue #339](https://github.com/aasm/aasm/pull/339) for details, thanks to [@long-long-float](https://github.com/long-long-float))
68
-
69
- ## 4.9.0
70
-
71
- * add support for callback classes (`after` only) (see [issue #316](https://github.com/aasm/aasm/pull/316) for details, thanks to [@mlr](https://github.com/mlr))
72
- * allow easier extension of _AASM_ (utilising the idea of _ApplicationRecords_ from _Rails 5_) (see [issue #296](https://github.com/aasm/aasm/pull/296) for details, thanks to [@mlr](https://github.com/mlr))
73
- * support pessimistic locking for _ActiveRecord_ (see [issue #283](https://github.com/aasm/aasm/pull/283) for details, thanks to [@HoyaBoya](https://github.com/HoyaBoya))
74
- * fix: support database sharding for _ActiveRecord_ (see [issue #289](https://github.com/aasm/aasm/pull/289) for details, thanks to [@scambra](https://github.com/scambra))
75
- * fix: some issues with RubyMotion (see [issue #318](https://github.com/aasm/aasm/pull/318) for details, thanks to [@Infotaku](https://github.com/Infotaku))
76
- * fix: Rails generator now features the correct namespace (see [issue #328](https://github.com/aasm/aasm/pull/328) and [issue #329](https://github.com/aasm/aasm/pull/329) for details, thanks to [@anilmaurya](https://github.com/anilmaurya))
77
-
78
-
79
- ## 4.8.0
80
-
81
- * add support for [dynamoid](http://joshsymonds.com/Dynamoid/) (see [issue #300](https://github.com/aasm/aasm/pull/300) for details, thanks to [@LeeChSien](https://github.com/LeeChSien))
82
- * make compatible with [RubyMotion](http://www.rubymotion.com) (see [issue #315](https://github.com/aasm/aasm/pull/315) for details, thanks to [@Infotaku](https://github.com/Infotaku))
83
- * improve error handling in case of an exception during transitioning (see [issue #275](https://github.com/aasm/aasm/pull/275) for details, thanks to [@chriswoodrich](https://github.com/chriswoodrich))
84
- * rspec matcher `on_event` now supports arguments (see [issue #309](https://github.com/aasm/aasm/pull/309) for details, thanks to [@zacviandier](https://github.com/zacviandier))
85
- * fix: permitted states now respect guards (see [issue #308](https://github.com/aasm/aasm/pull/308) for details, thanks to [@eebs](https://github.com/eebs))
86
- * fix: reloading the env now doesn't add callbacks twice anymore (see [issue #311](https://github.com/aasm/aasm/pull/311) for details, thanks to [@lingceng](https://github.com/lingceng))
87
-
88
- ## 4.7.0
89
-
90
- * fix: allow :send as event name (see [issue #257](https://github.com/aasm/aasm/issues/257) for details)
91
- * add new callbacks: transactions, all events, ensure (see [issue #282](https://github.com/aasm/aasm/issues/282) for details, thanks to [@HoyaBoya](https://github.com/HoyaBoya))
92
-
93
- ## 4.6.0
94
-
95
- * fix: make sure the column is actually present for _ActiveRecord_ enums (see [issue #265](https://github.com/aasm/aasm/issues/265) and [issue #152](https://github.com/aasm/aasm/issues/152) for details, thanks to [@anilmaurya](https://github.com/anilmaurya))
96
- * add generators to configure active_record and mongoid after install (see [issue #261](https://github.com/aasm/aasm/issues/261) for details, thanks to [@anilmaurya](https://github.com/anilmaurya))
97
-
98
- ## 4.5.2
99
-
100
- * fix arity difference between Procs and lambdas (see [issue #293](https://github.com/aasm/aasm/issues/293) for details)
101
-
102
- ## 4.5.1
103
-
104
- * make sure to use override configuration options if state machine is defined more than once (see [issue #287](https://github.com/aasm/aasm/issues/287) for details)
105
-
106
- ## 4.5.0
107
-
108
- * add RSpec matchers `have_state`, `allow_event` and `allow_transition_to` (see [issue #147](https://github.com/aasm/aasm/issues/147) for details)
109
- * add RSpec matcher `transition_from` (see [issue #178](https://github.com/aasm/aasm/issues/178) for details, thanks to [@thomasstephane](https://github.com/thomasstephane))
110
-
111
- ## 4.4.1
112
-
113
- * add support for rejecting certain events on inspection (see [issue #272](https://github.com/aasm/aasm/issues/272) for details, thanks to [@dubroe](https://github.com/dubroe))
114
-
115
- ## 4.4.0
116
-
117
- * add support global transation callbacks (see [issue #221](https://github.com/aasm/aasm/issues/221) and [issue #253](https://github.com/aasm/aasm/issues/253) for details)
118
- * add support (bugfix) for Mongoid >= 5.0 (see [issue #277](https://github.com/aasm/aasm/issues/277) and [issue #278](https://github.com/aasm/aasm/issues/278) for details)
119
-
120
- ## 4.3.0
121
-
122
- * add support for multiple state machines per class (see [issue #158](https://github.com/aasm/aasm/issues/158) and [issue #240](https://github.com/aasm/aasm/issues/240) for details)
123
- * special thanks to [@evadne](https://github.com/evadne) for testing this feature, and providing comments and patches (see [issue #245](https://github.com/aasm/aasm/issues/245) for details)
124
-
125
- ## 4.2.0
126
-
127
- * support turning off and on the configuration option for `no_direct_assignment` (see [issue #223](https://github.com/aasm/aasm/issues/223) for details)
128
- * event arguments are now passed to `:after_commit` callbacks as well (see [issue #238](https://github.com/aasm/aasm/pull/238), thanks to [@kuinak](https://github.com/kuinak))
129
-
130
- ## 4.1.1
131
-
132
- * support block notation for `:after_commit` event callbacks (see [issue #224](https://github.com/aasm/aasm/issues/224) for details)
133
- * event arguments are now passed to state callbacks as well (not only to event callbacks) (see [issue #219](https://github.com/aasm/aasm/issues/219), thanks to [@tobithiel](https://github.com/tobithiel))
134
- * `AASM::InvalidTransition` now references the current object (with the state machine) and the _AASM_ event name (see [issue #217](https://github.com/aasm/aasm/issues/217), thanks to [@awsmsrc](https://github.com/awsmsrc))
135
- * bugfix: do not update unloaded state for [Sequel](http://sequel.jeremyevans.net/) (see [issue #218](https://github.com/aasm/aasm/issues/218), thanks to [@godfat](https://github.com/godfat))
136
-
137
- ## 4.1.0
138
-
139
- * bugfix: initialize the aasm state column after initialization of the _Mongoid_ instance (see [issue #206](https://github.com/aasm/aasm/issues/206), thanks to [@Shwetakale ](https://github.com/Shwetakale ))
140
- * added support for mongomapper ORM (see [issue #203](https://github.com/aasm/aasm/issues/203), thanks to [@reidmorrison ](https://github.com/reidmorrison ))
141
- * `aasm_column` has been removed. Use `aasm.attribute_name` instead
142
- * `aasm_human_event_name` has been removed. Use `aasm.human_event_name` instead
143
-
144
- ## 4.0.8
145
-
146
- * bugfix: may_event_name? should return true or false only (see [issue #200](https://github.com/aasm/aasm/issues/200) for details)
147
-
148
- ## 4.0.7
149
-
150
- * bugfix: take private methods into account when checking for callbacks (see [issue #197](https://github.com/aasm/aasm/issues/197) for details)
151
-
152
- ## 4.0.6
153
-
154
- * bugfix: `false` is treated as uninitialised state (same as `nil`) (see [issue #195](https://github.com/aasm/aasm/issues/195) for details)
155
- * bugfix: an event's `:error` callback now retrieves all arguments passed to the event (see [issue #196](https://github.com/aasm/aasm/issues/196) for details)
156
-
157
- ## 4.0.5
158
-
159
- * bugfix: initialize the aasm state column after initialization of the _ActiveRecord_ instance only if the attribute has been loaded (see [issue #193](https://github.com/aasm/aasm/issues/193) for details)
160
-
161
- ## 4.0.4
162
-
163
- * corrected callback order in README
164
- * bugfix: initialize the aasm state column after initialization of the _ActiveRecord_ instance (see [issue #191](https://github.com/aasm/aasm/issues/191) for details)
165
- * bugfix: avoid Rails autoloading conflicts (see [issue #137](https://github.com/aasm/aasm/issues/137) and [issue #139](https://github.com/aasm/aasm/issues/139) for details)
166
-
167
- ## 4.0.3
168
-
169
- * bugfix: fire guards only once per transition, part 2 (see [issue #187](https://github.com/aasm/aasm/issues/187) for details)
170
- * `aasm_column` is deprecated. Use `aasm.attribute_name` instead
171
-
172
- ## 4.0.2
173
-
174
- * bugfix: really support block-guards (defined within a transition block) (see [issue #186](https://github.com/aasm/aasm/issues/186) for details)
175
-
176
- ## 4.0.1
177
-
178
- * fire guards only once per transition (see [issue #184](https://github.com/aasm/aasm/issues/184) for details)
179
- * `aasm_human_event_name` is deprecated, use `aasm.human_event_name` instead
180
-
181
- ## 4.0.0
182
-
183
- * support `if` and `unless` guard syntax: (see [issue #179](https://github.com/aasm/aasm/issues/179) and [issue #181](https://github.com/aasm/aasm/issues/181)), thanks to [@bigtunacan](https://github.com/bigtunacan)
184
- * may configure to not allow direct assignment for persisted AASM models (see [issue #53](https://github.com/aasm/aasm/issues/53))
185
- * **DSL change**: callbacks don't require `to_state` parameter anymore, but still support it
186
- (closing issues
187
- [#11](https://github.com/aasm/aasm/issues/11),
188
- [#58](https://github.com/aasm/aasm/issues/58) and
189
- [#80](https://github.com/aasm/aasm/issues/80)
190
- thanks to [@ejlangev](https://github.com/ejlangev))
191
- * **DSL change**: `after_commit` hooks are now event-based (see [issue #112](https://github.com/aasm/aasm/issues/112))
192
- * **DSL change**: event and state callbacks have been re-ordered; state callbacks are not run anymore if any guard fails
193
- * **DSL change**: `:on_transition` renamed to `:after`
194
- * **DSL change**: `:on_transition` renamed to `:after`
195
- * **DSL change**: transition `:after` binding changed (see [issue #59](https://github.com/aasm/aasm/issues/59), thanks to [@stiff](https://github.com/stiff))
196
- * **DSL change**: instance-based events inspection now returns event instances (instead of the event names as symbol)
197
- * **DSL change**: instance-based permissible_events has been removed in favor or events(:permissible => true)
198
- * **DSL change**: class-based events now returns a list of Event instances (instead of a hash with event names as keys)
199
- * **DSL change**: renamed permissible states and events to permitted states events
200
- * removed deprecated methods (mostly the ones prefixed with `aasm_`)
201
-
202
- ## 3.4.0
203
-
204
- * allow retrieving the current event (`aasm.current_event`) (see [issue #159](https://github.com/aasm/aasm/issues/159) and [issue #168](https://github.com/aasm/aasm/issues/168))
205
-
206
- ## 3.3.3
207
-
208
- * bugfix: support reloading development environment in Rails (see [issue #148](https://github.com/aasm/aasm/issues/148))
209
-
210
- ## 3.3.2
211
-
212
- * bugfix: avoid conflicts with `failed` and `fired` event names (see [issue #157](https://github.com/aasm/aasm/issues/157)), thanks to [@MichaelXavier](https://github.com/MichaelXavier)
213
- * bugfix: not using transactions unless saving to the database (see [issue #162](https://github.com/aasm/aasm/issues/162) and [issue #164](https://github.com/aasm/aasm/issues/164)), thanks to [@roberthoner](https://github.com/roberthoner)
214
- * bugfix: `after_commit` should only run if saving to the database (see [issue #151](https://github.com/aasm/aasm/issues/151)), thanks to [@ivantsepp](https://github.com/ivantsepp)
215
-
216
- ## 3.3.1
217
-
218
- * bugfix: permissible events will respect given `guards` (see [issue #150](https://github.com/aasm/aasm/issues/150))
219
-
220
- ## 3.3.0
221
-
222
- * support for Rails 4.1 enum fields (see [issue #124](https://github.com/aasm/aasm/issues/124), thanks to [@bkon](https://github.com/bkon))
223
- * bugfix: allow lazy-evaluation for Rails 3 scopes (see [issue #144](https://github.com/aasm/aasm/issues/144), thanks to [@laurens](https://github.com/laurens))
224
-
225
- ## 3.2.1
226
-
227
- * bugfix: permissible_events and events did not contain events with an empty "from" transition (see [issue #140](https://github.com/aasm/aasm/issues/140) and [issue #141](https://github.com/aasm/aasm/issues/141), thanks to [@daniel-rikowski](https://github.com/daniel-rikowski))
228
-
229
- ## 3.2.0
230
-
231
- * support [Sequel](http://sequel.jeremyevans.net/) (see [issue #119](https://github.com/aasm/aasm/issues/119), thanks to [@godfat](https://github.com/godfat))
232
- * may not fire an unknown event (see [issue #128](https://github.com/aasm/aasm/issues/128)
233
-
234
- ## 3.1.1
235
-
236
- * bugfix: don't require ActiveRecord for localizing AASM event and state name (see [issue #113](https://github.com/aasm/aasm/issues/113), thanks to [@silentshade](https://github.com/silentshade))
237
-
238
- ## 3.1.0
239
-
240
- * validating the current state (see [issue #95](https://github.com/aasm/aasm/issues/95), thanks to [@ivantsepp](https://github.com/ivantsepp))
241
- * allow configuring behavior of nested transactions (see [issue #107](https://github.com/aasm/aasm/issues/107))
242
- * support multiple guards per transition
243
- * support event guards (see [issue #85](https://github.com/aasm/aasm/issues/85))
244
- * support reading from- and to-state during on_transition callback (see [issue #100](https://github.com/aasm/aasm/issues/100))
245
-
246
- ## 3.0.26
247
-
248
- * support state.human_name (aliased to state.localized_name) (see [issue #105](https://github.com/aasm/aasm/issues/105))
249
-
250
- ## 3.0.25
251
-
252
- * initialize the state even if validation is skipped (for ActiveRecord and Mongoid persistence) (see [issue #103](https://github.com/aasm/aasm/issues/103), thanks to [@vfonic](https://github.com/vfonic) and [@aaronklaassen](https://github.com/aaronklaassen))
253
-
254
- ## 3.0.24
255
-
256
- * added support for event blocks (thanks to [@Intrepidd](https://github.com/Intrepidd))
257
-
258
- ## 3.0.23
259
-
260
- * added support for `after_commit` callback (transaction support) (thanks to [@tisba](https://github.com/tisba))
261
-
262
- ## 3.0.22
263
-
264
- * fixed [issue 88](https://github.com/aasm/aasm/issues/88): wrong number of arguments for transaction method
265
-
266
- ## 3.0.21
267
-
268
- * support nested ActiveRecord transactions ([@ozeias](https://github.com/ozeias))
269
- * allow overwriting of events, can be very useful with inheritance ([@Intrepidd](https://github.com/Intrepidd))
270
-
271
- ## 3.0.20
272
-
273
- * added configuration option to disable automatic scope creation
274
-
275
- ## 3.0.19
276
-
277
- * fixed deprecation warning with *Rails 4* (`Relation#update_all` with conditions is deprecated)
278
- * fixing [issue #69](https://github.com/aasm/aasm/issues/69) ( *ActiveRecord* scopes are not chainable)
279
-
280
- ## 3.0.18
281
-
282
- * fixing [issue #66](https://github.com/aasm/aasm/issues/66) (state methods not reflecting the current state)
283
-
284
- ## 3.0.17
285
-
286
- * supporting instance level inspection for states (including permissible state, see [issue #54](https://github.com/aasm/aasm/issues/54))
287
- * added autocreation of constants for each state ([@jherdman](https://github.com/jherdman))
288
-
289
- ## 3.0.16
290
-
291
- * added autocreation of state scopes for Mongoid (thanks to [@jonnyshields](https://github.com/johnnyshields))
292
-
293
- ## 3.0.15
294
-
295
- * added support for localized state names (on a class level, like `Record.aasm.states.map(&:localized_name)`)
296
-
297
- ## 3.0.14
298
-
299
- * supporting event inspection for to-states transitions (`Event#transitions_to_state?`)
300
-
301
- ## 3.0.13
302
-
303
- * supporting *ActiveRecord* transactions when firing an event
304
-
305
- ## 3.0.12
306
-
307
- * `aasm_from_states_for_state` now supports to filter for specific transition
308
-
309
- ## 3.0.11
310
-
311
- * added class method `aasm_from_states_for_state` to retrieve all from states (regarding transitions) for a given state
312
-
313
- ## 3.0.10
314
-
315
- * added support for transitions from all other states (thanks to [@swrobel](https://github.com/swrobel))
316
-
317
- ## 3.0.9
318
-
319
- * guard checks (e.g. `may_edit?`) now support guard parameters as well
320
-
321
- ## 3.0.8
322
-
323
- * fixed issue with generating docs using yard
324
-
325
- ## 3.0.7
326
-
327
- * removed deprecation warning when localizing aasm state names (look at [issue #38](https://github.com/rubyist/aasm/issues/38) for details)
328
-
329
- ## 3.0.6
330
-
331
- * bugfix: if configured to skip validation the code does not validate anymore
332
-
333
- ## 3.0.5
334
-
335
- * bugfix: get rid of error with old rubygems versions
336
-
337
- ## 3.0.4
338
-
339
- * bugfix: Subclasses of aasm-enabled classes don't lose settings anymore (thanks to codez)
340
-
341
- ## 3.0.3
342
-
343
- * bugfix: ActiveRecord scopes are generated when using the new DSL
344
-
345
- ## 3.0.2
346
-
347
- * ActiveRecord persistence can ignore validation when trying to save invalid models
348
-
349
- ## 3.0.1
350
-
351
- * added support for Mongoid (Thanks, Michał Taberski)
352
-
353
- ## 3.0.0
354
-
355
- * switched documentation to the new DSL
356
- * whiny transactions: by default, raise an exception if an event transition is not possible
357
- * you may disable whiny transactions
358
-
359
- ## 2.4.0
360
-
361
- * supporting new DSL (which is much shorter)
362
-
363
- ## 2.3.1
364
-
365
- * bugfix: avoid naming conflict with i18n
366
-
367
- ## 2.3.0
368
-
369
- * supporting i18n
370
- * supporting regular expressions for hash values and strings
data/CODE_OF_CONDUCT.md DELETED
@@ -1,13 +0,0 @@
1
- # Contributor Code of Conduct
2
-
3
- As contributors and maintainers of this project, we pledge to respect all people who contribute through reporting issues, posting feature requests, updating documentation, submitting pull requests or patches, and other activities.
4
-
5
- We are committed to making participation in this project a harassment-free experience for everyone, regardless of level of experience, gender, gender identity and expression, sexual orientation, disability, personal appearance, body size, race, ethnicity, age, or religion.
6
-
7
- Examples of unacceptable behavior by participants include the use of sexual language or imagery, derogatory comments or personal attacks, trolling, public or private harassment, insults, or other unprofessional conduct.
8
-
9
- Project maintainers have the right and responsibility to remove, edit, or reject comments, commits, code, wiki edits, issues, and other contributions that are not aligned to this Code of Conduct. Project maintainers who do not follow the Code of Conduct may be removed from the project team.
10
-
11
- Instances of abusive, harassing, or otherwise unacceptable behavior may be reported by opening an issue or contacting one or more of the project maintainers.
12
-
13
- This Code of Conduct is adapted from the [Contributor Covenant](http:contributor-covenant.org), version 1.0.0, available at [http://contributor-covenant.org/version/1/0/0/](http://contributor-covenant.org/version/1/0/0/)
data/CONTRIBUTING.md DELETED
@@ -1,24 +0,0 @@
1
- ## Contributing ##
2
-
3
- While not required to contribute, we recommend [RVM](https://rvm.io/) to manage your rubies.
4
-
5
- 1. Read the [Contributor Code of Conduct](https://github.com/aasm/aasm/blob/master/CODE_OF_CONDUCT.md)
6
- 2. [Fork it](https://help.github.com/articles/about-forks/)
7
- 3. Clone the project `git clone git@github.com:[YOUR GITHUB USERNAME]/aasm.git`
8
- 4. `cd aasm`
9
- 5. Create your feature branch `git checkout -b my-new-feature`
10
- 6. Write tests for your changes (feature/bug)
11
- 7. Write your (feature/bugfix)
12
- 8. Install the dependencies `appraisal install`
13
- 9. Run the tests `appraisal rspec`
14
- 10. Commit your changes `git commit -am 'Added some feature'`
15
- 11. Push to the branch `git push origin my-new-feature`
16
- 12. Create new [Pull Request](https://help.github.com/articles/creating-a-pull-request/)
17
-
18
- There are some option dependencies as well.
19
-
20
- - [MongoDB server](https://www.mongodb.com/download-center)
21
- - [Redis](https://redis.io/topics/quickstart)
22
- - [DynamoDB (local)](https://docs.aws.amazon.com/amazondynamodb/latest/developerguide/DynamoDBLocal.html)
23
-
24
- If we've missed something please open an [issue](https://github.com/aasm/aasm/issues/new)
data/Gemfile DELETED
@@ -1,7 +0,0 @@
1
- source "https://rubygems.org"
2
-
3
- gemspec
4
-
5
- gem 'sqlite3', :platforms => :ruby
6
- gem 'activerecord-jdbcsqlite3-adapter', :platforms => :jruby
7
- gem 'rails', '5.1.3'