active_type 2.5.0 → 2.6.0

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 9b40a092b72f6361e4693545466f24456c99e8bcb99544b151ea3f2d7fc81dba
4
- data.tar.gz: 25e7245a8e46d79a7ceb1e7de19c869e8cee5af3aabca774db5bd12e500e6a97
3
+ metadata.gz: 970684d2b41b30fef4a53c0d4ab29ef2d25a7ca391be73a21295cfd07ef527a5
4
+ data.tar.gz: 0d0b34b0af58796b9cb6d877470894da5484a1658ef3a4704d603b9cbbf45c57
5
5
  SHA512:
6
- metadata.gz: 15b0593912cfafd848d498cc9095928e30f925b5e1fdc82c1bdbb0e34e543f5b5f6ae981f003bd9eece9e8f3ab957daaf0b779980002b847bea73296719de286
7
- data.tar.gz: 7b823c166979fe0786e455a39e81cf633db3784aa91a47e9c34491082489e7a7049e2997c46cc9470830fccab063c7ac693feba97eab897cea995d675cae12ae
6
+ metadata.gz: 24e437dc4e496c086c1789e01a0e47571541f9557f8585e822c53b9e5001b62d676a9ec1476ac075c6a1cd014584c1121a1d898cfeb09cb2a9b7ce1f20deb190
7
+ data.tar.gz: 34a47671ac54c98464fd2ecdfd1d8ca528e2b43e29d571688e7a63d0d60b3f8848192d16c536fe16159ae1fc340ca37debc19a765786b335957c0fdb41c68e4e
@@ -14,20 +14,16 @@ jobs:
14
14
  fail-fast: false
15
15
  matrix:
16
16
  include:
17
- - ruby: "2.5.5"
18
- gemfile: Gemfile.5.2.sqlite3
19
- - ruby: "2.7.7"
20
- gemfile: Gemfile.5.2.sqlite3
21
- - ruby: "3.0.5"
22
- gemfile: Gemfile.6.0.sqlite3
23
- - ruby: "3.0.5"
17
+ - ruby: "2.7.8"
24
18
  gemfile: Gemfile.6.1.sqlite3
25
- - ruby: "3.0.5"
26
- gemfile: Gemfile.7.0.sqlite3
27
- - ruby: "3.1.3"
28
- gemfile: Gemfile.7.0.sqlite3
29
- - ruby: "3.2.0"
30
- gemfile: Gemfile.7.0.sqlite3
19
+ - ruby: "3.0.7"
20
+ gemfile: Gemfile.7.1.sqlite3
21
+ - ruby: "3.1.6"
22
+ gemfile: Gemfile.7.2.sqlite3
23
+ - ruby: "3.2.6"
24
+ gemfile: Gemfile.7.2.sqlite3
25
+ - ruby: "3.3.6"
26
+ gemfile: Gemfile.8.0.sqlite3
31
27
  env:
32
28
  BUNDLE_GEMFILE: ${{ matrix.gemfile }}
33
29
 
@@ -61,8 +57,8 @@ jobs:
61
57
  fail-fast: false
62
58
  matrix:
63
59
  include:
64
- - ruby: "2.7.7"
65
- gemfile: Gemfile.5.2.mysql2
60
+ - ruby: "3.2.6"
61
+ gemfile: Gemfile.7.2.mysql2
66
62
  env:
67
63
  BUNDLE_GEMFILE: ${{ matrix.gemfile }}
68
64
 
@@ -100,18 +96,12 @@ jobs:
100
96
  fail-fast: false
101
97
  matrix:
102
98
  include:
103
- - ruby: "2.5.5"
104
- gemfile: Gemfile.5.2.pg
105
- - ruby: "2.7.7"
106
- gemfile: Gemfile.5.2.pg
107
- - ruby: "3.0.5"
99
+ - ruby: "3.0.7"
108
100
  gemfile: Gemfile.6.1.pg
109
- - ruby: "3.0.5"
110
- gemfile: Gemfile.7.0.pg
111
- - ruby: "3.1.3"
112
- gemfile: Gemfile.7.0.pg
113
- - ruby: "3.2.0"
114
- gemfile: Gemfile.7.0.pg
101
+ - ruby: "3.2.6"
102
+ gemfile: Gemfile.7.1.pg
103
+ - ruby: "3.2.6"
104
+ gemfile: Gemfile.7.2.pg
115
105
  env:
116
106
  BUNDLE_GEMFILE: ${{ matrix.gemfile }}
117
107
 
data/.ruby-version CHANGED
@@ -1 +1 @@
1
- 3.0
1
+ 3.2
data/CHANGELOG.md CHANGED
@@ -2,6 +2,14 @@
2
2
 
3
3
  All notable changes to this project will be documented in this file.
4
4
 
5
+ ## 2.6.0 (2024-12-20)
6
+
7
+ * Dropped support for Rails < 6 and Ruby < 2.7.
8
+
9
+ ## 2.5.1 (2024-08-14)
10
+
11
+ * Fixed: Make `ActiveType::Object` work on Rails 7.2.
12
+
5
13
  ## 2.5.0 (2024-02-29)
6
14
 
7
15
  * Passing unfrozen objects as a default for an attribute is deprecated, since these objects might be shared between records.
@@ -11,6 +19,7 @@ All notable changes to this project will be documented in this file.
11
19
  * Fixed: Calling `#attributes` on the base record after a cast works now and does not throw a `MutationAfterCastError`
12
20
 
13
21
  ## 2.4.0 (2023-12-22)
22
+
14
23
  * Added: You can implement an `#after_cast` that is called with the original record when calling `ActiveType.cast`.
15
24
  Thanks to @MaximilianoGarciaRoe.
16
25
 
data/Gemfile.6.1.pg.lock CHANGED
@@ -1,8 +1,8 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- active_type (2.5.0)
5
- activerecord (>= 3.2)
4
+ active_type (2.6.0)
5
+ activerecord (>= 6.1)
6
6
 
7
7
  GEM
8
8
  remote: https://rubygems.org/
@@ -1,8 +1,8 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- active_type (2.5.0)
5
- activerecord (>= 3.2)
4
+ active_type (2.6.0)
5
+ activerecord (>= 6.1)
6
6
 
7
7
  GEM
8
8
  remote: https://rubygems.org/
@@ -1,6 +1,6 @@
1
1
  source 'https://rubygems.org'
2
2
 
3
- gem 'activerecord', '~>7.0.3'
3
+ gem 'activerecord', '~>7.1.0'
4
4
  gem 'rspec', '~>3.4'
5
5
  gem 'pg'
6
6
  gem 'rake'
@@ -0,0 +1,68 @@
1
+ PATH
2
+ remote: .
3
+ specs:
4
+ active_type (2.6.0)
5
+ activerecord (>= 6.1)
6
+
7
+ GEM
8
+ remote: https://rubygems.org/
9
+ specs:
10
+ activemodel (7.1.3.4)
11
+ activesupport (= 7.1.3.4)
12
+ activerecord (7.1.3.4)
13
+ activemodel (= 7.1.3.4)
14
+ activesupport (= 7.1.3.4)
15
+ timeout (>= 0.4.0)
16
+ activesupport (7.1.3.4)
17
+ base64
18
+ bigdecimal
19
+ concurrent-ruby (~> 1.0, >= 1.0.2)
20
+ connection_pool (>= 2.2.5)
21
+ drb
22
+ i18n (>= 1.6, < 2)
23
+ minitest (>= 5.1)
24
+ mutex_m
25
+ tzinfo (~> 2.0)
26
+ base64 (0.2.0)
27
+ bigdecimal (3.1.8)
28
+ concurrent-ruby (1.3.4)
29
+ connection_pool (2.4.1)
30
+ diff-lcs (1.5.1)
31
+ drb (2.2.1)
32
+ gemika (0.8.3)
33
+ i18n (1.14.5)
34
+ concurrent-ruby (~> 1.0)
35
+ minitest (5.24.1)
36
+ mutex_m (0.2.0)
37
+ pg (1.5.7)
38
+ rake (13.2.1)
39
+ rspec (3.13.0)
40
+ rspec-core (~> 3.13.0)
41
+ rspec-expectations (~> 3.13.0)
42
+ rspec-mocks (~> 3.13.0)
43
+ rspec-core (3.13.0)
44
+ rspec-support (~> 3.13.0)
45
+ rspec-expectations (3.13.1)
46
+ diff-lcs (>= 1.2.0, < 2.0)
47
+ rspec-support (~> 3.13.0)
48
+ rspec-mocks (3.13.1)
49
+ diff-lcs (>= 1.2.0, < 2.0)
50
+ rspec-support (~> 3.13.0)
51
+ rspec-support (3.13.1)
52
+ timeout (0.4.1)
53
+ tzinfo (2.0.6)
54
+ concurrent-ruby (~> 1.0)
55
+
56
+ PLATFORMS
57
+ ruby
58
+
59
+ DEPENDENCIES
60
+ active_type!
61
+ activerecord (~> 7.1.0)
62
+ gemika
63
+ pg
64
+ rake
65
+ rspec (~> 3.4)
66
+
67
+ BUNDLED WITH
68
+ 2.5.6
@@ -1,8 +1,8 @@
1
1
  source 'https://rubygems.org'
2
2
 
3
- gem 'activerecord', '~>6.0.0'
3
+ gem 'activerecord', '~>7.1.0'
4
4
  gem 'rspec', '~>3.4'
5
- gem 'sqlite3'
5
+ gem 'sqlite3', '=1.6.0'
6
6
  gem 'rake'
7
7
  gem 'gemika'
8
8
 
@@ -0,0 +1,70 @@
1
+ PATH
2
+ remote: .
3
+ specs:
4
+ active_type (2.6.0)
5
+ activerecord (>= 6.1)
6
+
7
+ GEM
8
+ remote: https://rubygems.org/
9
+ specs:
10
+ activemodel (7.1.3.4)
11
+ activesupport (= 7.1.3.4)
12
+ activerecord (7.1.3.4)
13
+ activemodel (= 7.1.3.4)
14
+ activesupport (= 7.1.3.4)
15
+ timeout (>= 0.4.0)
16
+ activesupport (7.1.3.4)
17
+ base64
18
+ bigdecimal
19
+ concurrent-ruby (~> 1.0, >= 1.0.2)
20
+ connection_pool (>= 2.2.5)
21
+ drb
22
+ i18n (>= 1.6, < 2)
23
+ minitest (>= 5.1)
24
+ mutex_m
25
+ tzinfo (~> 2.0)
26
+ base64 (0.2.0)
27
+ bigdecimal (3.1.8)
28
+ concurrent-ruby (1.3.4)
29
+ connection_pool (2.4.1)
30
+ diff-lcs (1.5.1)
31
+ drb (2.2.1)
32
+ gemika (0.8.3)
33
+ i18n (1.14.5)
34
+ concurrent-ruby (~> 1.0)
35
+ mini_portile2 (2.8.7)
36
+ minitest (5.24.1)
37
+ mutex_m (0.2.0)
38
+ rake (13.2.1)
39
+ rspec (3.13.0)
40
+ rspec-core (~> 3.13.0)
41
+ rspec-expectations (~> 3.13.0)
42
+ rspec-mocks (~> 3.13.0)
43
+ rspec-core (3.13.0)
44
+ rspec-support (~> 3.13.0)
45
+ rspec-expectations (3.13.1)
46
+ diff-lcs (>= 1.2.0, < 2.0)
47
+ rspec-support (~> 3.13.0)
48
+ rspec-mocks (3.13.1)
49
+ diff-lcs (>= 1.2.0, < 2.0)
50
+ rspec-support (~> 3.13.0)
51
+ rspec-support (3.13.1)
52
+ sqlite3 (1.6.0)
53
+ mini_portile2 (~> 2.8.0)
54
+ timeout (0.4.1)
55
+ tzinfo (2.0.6)
56
+ concurrent-ruby (~> 1.0)
57
+
58
+ PLATFORMS
59
+ ruby
60
+
61
+ DEPENDENCIES
62
+ active_type!
63
+ activerecord (~> 7.1.0)
64
+ gemika
65
+ rake
66
+ rspec (~> 3.4)
67
+ sqlite3 (= 1.6.0)
68
+
69
+ BUNDLED WITH
70
+ 2.5.6
@@ -1,6 +1,6 @@
1
1
  source 'https://rubygems.org'
2
2
 
3
- gem 'activerecord', '~>5.1.0'
3
+ gem 'activerecord', '~>7.2.0'
4
4
  gem 'rspec', '~>3.4'
5
5
  gem 'mysql2'
6
6
  gem 'rake'
@@ -0,0 +1,73 @@
1
+ PATH
2
+ remote: .
3
+ specs:
4
+ active_type (2.6.0)
5
+ activerecord (>= 6.1)
6
+
7
+ GEM
8
+ remote: https://rubygems.org/
9
+ specs:
10
+ activemodel (7.2.2.1)
11
+ activesupport (= 7.2.2.1)
12
+ activerecord (7.2.2.1)
13
+ activemodel (= 7.2.2.1)
14
+ activesupport (= 7.2.2.1)
15
+ timeout (>= 0.4.0)
16
+ activesupport (7.2.2.1)
17
+ base64
18
+ benchmark (>= 0.3)
19
+ bigdecimal
20
+ concurrent-ruby (~> 1.0, >= 1.3.1)
21
+ connection_pool (>= 2.2.5)
22
+ drb
23
+ i18n (>= 1.6, < 2)
24
+ logger (>= 1.4.2)
25
+ minitest (>= 5.1)
26
+ securerandom (>= 0.3)
27
+ tzinfo (~> 2.0, >= 2.0.5)
28
+ base64 (0.2.0)
29
+ benchmark (0.4.0)
30
+ bigdecimal (3.1.8)
31
+ concurrent-ruby (1.3.4)
32
+ connection_pool (2.4.1)
33
+ diff-lcs (1.5.1)
34
+ drb (2.2.1)
35
+ gemika (0.8.3)
36
+ i18n (1.14.6)
37
+ concurrent-ruby (~> 1.0)
38
+ logger (1.6.4)
39
+ minitest (5.25.4)
40
+ mysql2 (0.5.6)
41
+ rake (13.2.1)
42
+ rspec (3.13.0)
43
+ rspec-core (~> 3.13.0)
44
+ rspec-expectations (~> 3.13.0)
45
+ rspec-mocks (~> 3.13.0)
46
+ rspec-core (3.13.2)
47
+ rspec-support (~> 3.13.0)
48
+ rspec-expectations (3.13.3)
49
+ diff-lcs (>= 1.2.0, < 2.0)
50
+ rspec-support (~> 3.13.0)
51
+ rspec-mocks (3.13.2)
52
+ diff-lcs (>= 1.2.0, < 2.0)
53
+ rspec-support (~> 3.13.0)
54
+ rspec-support (3.13.2)
55
+ securerandom (0.4.1)
56
+ timeout (0.4.3)
57
+ tzinfo (2.0.6)
58
+ concurrent-ruby (~> 1.0)
59
+
60
+ PLATFORMS
61
+ ruby
62
+ x86_64-linux
63
+
64
+ DEPENDENCIES
65
+ active_type!
66
+ activerecord (~> 7.2.0)
67
+ gemika
68
+ mysql2
69
+ rake
70
+ rspec (~> 3.4)
71
+
72
+ BUNDLED WITH
73
+ 2.6.1
@@ -1,6 +1,6 @@
1
1
  source 'https://rubygems.org'
2
2
 
3
- gem 'activerecord', '~>5.1.0'
3
+ gem 'activerecord', '~>7.2.0'
4
4
  gem 'rspec', '~>3.4'
5
5
  gem 'pg'
6
6
  gem 'rake'
@@ -0,0 +1,70 @@
1
+ PATH
2
+ remote: .
3
+ specs:
4
+ active_type (2.6.0)
5
+ activerecord (>= 6.1)
6
+
7
+ GEM
8
+ remote: https://rubygems.org/
9
+ specs:
10
+ activemodel (7.2.0)
11
+ activesupport (= 7.2.0)
12
+ activerecord (7.2.0)
13
+ activemodel (= 7.2.0)
14
+ activesupport (= 7.2.0)
15
+ timeout (>= 0.4.0)
16
+ activesupport (7.2.0)
17
+ base64
18
+ bigdecimal
19
+ concurrent-ruby (~> 1.0, >= 1.3.1)
20
+ connection_pool (>= 2.2.5)
21
+ drb
22
+ i18n (>= 1.6, < 2)
23
+ logger (>= 1.4.2)
24
+ minitest (>= 5.1)
25
+ securerandom (>= 0.3)
26
+ tzinfo (~> 2.0, >= 2.0.5)
27
+ base64 (0.2.0)
28
+ bigdecimal (3.1.8)
29
+ concurrent-ruby (1.3.4)
30
+ connection_pool (2.4.1)
31
+ diff-lcs (1.5.1)
32
+ drb (2.2.1)
33
+ gemika (0.8.3)
34
+ i18n (1.14.5)
35
+ concurrent-ruby (~> 1.0)
36
+ logger (1.6.0)
37
+ minitest (5.24.1)
38
+ pg (1.5.7)
39
+ rake (13.2.1)
40
+ rspec (3.13.0)
41
+ rspec-core (~> 3.13.0)
42
+ rspec-expectations (~> 3.13.0)
43
+ rspec-mocks (~> 3.13.0)
44
+ rspec-core (3.13.0)
45
+ rspec-support (~> 3.13.0)
46
+ rspec-expectations (3.13.1)
47
+ diff-lcs (>= 1.2.0, < 2.0)
48
+ rspec-support (~> 3.13.0)
49
+ rspec-mocks (3.13.1)
50
+ diff-lcs (>= 1.2.0, < 2.0)
51
+ rspec-support (~> 3.13.0)
52
+ rspec-support (3.13.1)
53
+ securerandom (0.3.1)
54
+ timeout (0.4.1)
55
+ tzinfo (2.0.6)
56
+ concurrent-ruby (~> 1.0)
57
+
58
+ PLATFORMS
59
+ ruby
60
+
61
+ DEPENDENCIES
62
+ active_type!
63
+ activerecord (~> 7.2.0)
64
+ gemika
65
+ pg
66
+ rake
67
+ rspec (~> 3.4)
68
+
69
+ BUNDLED WITH
70
+ 2.5.6
@@ -0,0 +1,9 @@
1
+ source 'https://rubygems.org'
2
+
3
+ gem 'activerecord', '~>7.2.0'
4
+ gem 'rspec', '~>3.4'
5
+ gem 'sqlite3', '=1.6.0'
6
+ gem 'rake'
7
+ gem 'gemika'
8
+
9
+ gem 'active_type', :path => '.'
@@ -0,0 +1,72 @@
1
+ PATH
2
+ remote: .
3
+ specs:
4
+ active_type (2.6.0)
5
+ activerecord (>= 6.1)
6
+
7
+ GEM
8
+ remote: https://rubygems.org/
9
+ specs:
10
+ activemodel (7.2.0)
11
+ activesupport (= 7.2.0)
12
+ activerecord (7.2.0)
13
+ activemodel (= 7.2.0)
14
+ activesupport (= 7.2.0)
15
+ timeout (>= 0.4.0)
16
+ activesupport (7.2.0)
17
+ base64
18
+ bigdecimal
19
+ concurrent-ruby (~> 1.0, >= 1.3.1)
20
+ connection_pool (>= 2.2.5)
21
+ drb
22
+ i18n (>= 1.6, < 2)
23
+ logger (>= 1.4.2)
24
+ minitest (>= 5.1)
25
+ securerandom (>= 0.3)
26
+ tzinfo (~> 2.0, >= 2.0.5)
27
+ base64 (0.2.0)
28
+ bigdecimal (3.1.8)
29
+ concurrent-ruby (1.3.4)
30
+ connection_pool (2.4.1)
31
+ diff-lcs (1.5.1)
32
+ drb (2.2.1)
33
+ gemika (0.8.3)
34
+ i18n (1.14.5)
35
+ concurrent-ruby (~> 1.0)
36
+ logger (1.6.0)
37
+ mini_portile2 (2.8.7)
38
+ minitest (5.24.1)
39
+ rake (13.2.1)
40
+ rspec (3.13.0)
41
+ rspec-core (~> 3.13.0)
42
+ rspec-expectations (~> 3.13.0)
43
+ rspec-mocks (~> 3.13.0)
44
+ rspec-core (3.13.0)
45
+ rspec-support (~> 3.13.0)
46
+ rspec-expectations (3.13.1)
47
+ diff-lcs (>= 1.2.0, < 2.0)
48
+ rspec-support (~> 3.13.0)
49
+ rspec-mocks (3.13.1)
50
+ diff-lcs (>= 1.2.0, < 2.0)
51
+ rspec-support (~> 3.13.0)
52
+ rspec-support (3.13.1)
53
+ securerandom (0.3.1)
54
+ sqlite3 (1.6.0)
55
+ mini_portile2 (~> 2.8.0)
56
+ timeout (0.4.1)
57
+ tzinfo (2.0.6)
58
+ concurrent-ruby (~> 1.0)
59
+
60
+ PLATFORMS
61
+ ruby
62
+
63
+ DEPENDENCIES
64
+ active_type!
65
+ activerecord (~> 7.2.0)
66
+ gemika
67
+ rake
68
+ rspec (~> 3.4)
69
+ sqlite3 (= 1.6.0)
70
+
71
+ BUNDLED WITH
72
+ 2.5.6
@@ -1,6 +1,6 @@
1
1
  source 'https://rubygems.org'
2
2
 
3
- gem 'activerecord', '~>7.0.3'
3
+ gem 'activerecord', '~>8.0.0'
4
4
  gem 'rspec', '~>3.4'
5
5
  gem 'sqlite3'
6
6
  gem 'rake'
@@ -0,0 +1,84 @@
1
+ PATH
2
+ remote: .
3
+ specs:
4
+ active_type (2.6.0)
5
+ activerecord (>= 6.1)
6
+
7
+ GEM
8
+ remote: https://rubygems.org/
9
+ specs:
10
+ activemodel (8.0.1)
11
+ activesupport (= 8.0.1)
12
+ activerecord (8.0.1)
13
+ activemodel (= 8.0.1)
14
+ activesupport (= 8.0.1)
15
+ timeout (>= 0.4.0)
16
+ activesupport (8.0.1)
17
+ base64
18
+ benchmark (>= 0.3)
19
+ bigdecimal
20
+ concurrent-ruby (~> 1.0, >= 1.3.1)
21
+ connection_pool (>= 2.2.5)
22
+ drb
23
+ i18n (>= 1.6, < 2)
24
+ logger (>= 1.4.2)
25
+ minitest (>= 5.1)
26
+ securerandom (>= 0.3)
27
+ tzinfo (~> 2.0, >= 2.0.5)
28
+ uri (>= 0.13.1)
29
+ base64 (0.2.0)
30
+ benchmark (0.4.0)
31
+ bigdecimal (3.1.8)
32
+ concurrent-ruby (1.3.4)
33
+ connection_pool (2.4.1)
34
+ diff-lcs (1.5.1)
35
+ drb (2.2.1)
36
+ gemika (0.8.3)
37
+ i18n (1.14.6)
38
+ concurrent-ruby (~> 1.0)
39
+ logger (1.6.4)
40
+ minitest (5.25.4)
41
+ rake (13.2.1)
42
+ rspec (3.13.0)
43
+ rspec-core (~> 3.13.0)
44
+ rspec-expectations (~> 3.13.0)
45
+ rspec-mocks (~> 3.13.0)
46
+ rspec-core (3.13.2)
47
+ rspec-support (~> 3.13.0)
48
+ rspec-expectations (3.13.3)
49
+ diff-lcs (>= 1.2.0, < 2.0)
50
+ rspec-support (~> 3.13.0)
51
+ rspec-mocks (3.13.2)
52
+ diff-lcs (>= 1.2.0, < 2.0)
53
+ rspec-support (~> 3.13.0)
54
+ rspec-support (3.13.2)
55
+ securerandom (0.4.1)
56
+ sqlite3 (2.4.1-aarch64-linux-gnu)
57
+ sqlite3 (2.4.1-arm-linux-gnu)
58
+ sqlite3 (2.4.1-arm64-darwin)
59
+ sqlite3 (2.4.1-x86-linux-gnu)
60
+ sqlite3 (2.4.1-x86_64-darwin)
61
+ sqlite3 (2.4.1-x86_64-linux-gnu)
62
+ timeout (0.4.3)
63
+ tzinfo (2.0.6)
64
+ concurrent-ruby (~> 1.0)
65
+ uri (1.0.2)
66
+
67
+ PLATFORMS
68
+ aarch64-linux
69
+ arm-linux
70
+ arm64-darwin
71
+ x86-linux
72
+ x86_64-darwin
73
+ x86_64-linux
74
+
75
+ DEPENDENCIES
76
+ active_type!
77
+ activerecord (~> 8.0.0)
78
+ gemika
79
+ rake
80
+ rspec (~> 3.4)
81
+ sqlite3
82
+
83
+ BUNDLED WITH
84
+ 2.6.1
data/README.md CHANGED
@@ -1,5 +1,21 @@
1
- ActiveType [![Tests](https://github.com/makandra/active_type/workflows/Tests/badge.svg)](https://github.com/makandra/active_type/actions)
2
- ==========
1
+ <p>
2
+ <a href="https://makandra.de/">
3
+ <picture>
4
+ <source media="(prefers-color-scheme: light)" srcset="media/makandra-with-bottom-margin.light.svg">
5
+ <source media="(prefers-color-scheme: dark)" srcset="media/makandra-with-bottom-margin.dark.svg">
6
+ <img align="right" width="25%" alt="makandra" src="media/makandra-with-bottom-margin.light.svg">
7
+ </picture>
8
+ </a>
9
+
10
+ <picture>
11
+ <source media="(prefers-color-scheme: light)" srcset="media/logo.light.shapes.svg">
12
+ <source media="(prefers-color-scheme: dark)" srcset="media/logo.dark.shapes.svg">
13
+ <img width="245" alt="active_type" role="heading" aria-level="1" src="media/logo.light.shapes.svg">
14
+ </picture>
15
+ </p>
16
+
17
+ [![Tests](https://github.com/makandra/active_type/workflows/Tests/badge.svg)](https://github.com/makandra/active_type/actions)
18
+
3
19
 
4
20
  Make any Ruby object quack like ActiveRecord
5
21
  --------------------------------------------
@@ -381,12 +397,13 @@ sign_up.is_a?(SignUp) # => true
381
397
 
382
398
  If you need to add some special logic after casting you can add an `after_cast` method:
383
399
 
400
+ ```ruby
384
401
  class SignUp < ActiveType::Record[User]
385
402
  def after_cast(user)
386
403
  # Called with the original user upon casting.
387
404
  end
388
405
  end
389
-
406
+ ```
390
407
 
391
408
 
392
409
  Associations
@@ -395,7 +412,7 @@ Associations
395
412
  Sometimes, you have an association, and a form model for that association. Instead of always casting the associations manually, you can use the `change_association` macro to override an association's options. For example.
396
413
 
397
414
 
398
- ```
415
+ ```ruby
399
416
  class Credential < ActiveRecord::Base
400
417
  end
401
418
 
@@ -417,14 +434,14 @@ Now, if you load `credentials`, you will automatically receive records of type `
417
434
  Supported Rails versions
418
435
  ------------------------
419
436
 
420
- ActiveType is tested against ActiveRecord 5.2, 6.0, 6.1, and 7.0.
437
+ ActiveType is tested against ActiveRecord 6.1, 7.1, 7.2, 8.0.
421
438
 
422
439
  Later versions might work, earlier will not.
423
440
 
424
441
  Supported Ruby versions
425
442
  ------------------------
426
443
 
427
- ActiveType is tested against 2.5, 2.7, 3.0, and 3.1.
444
+ ActiveType is tested against Ruby 2.7+.
428
445
 
429
446
 
430
447
  Installation