media_types-serialization 2.0.4 → 2.1.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 (42) hide show
  1. checksums.yaml +4 -4
  2. data/.github/workflows/ci.yml +32 -32
  3. data/.github/workflows/publish-bookworm.yml +34 -34
  4. data/.github/workflows/publish-sid.yml +34 -34
  5. data/.gitignore +22 -22
  6. data/.idea/.rakeTasks +7 -7
  7. data/.idea/dictionaries/Derk_Jan.xml +6 -6
  8. data/.idea/encodings.xml +3 -3
  9. data/.idea/inspectionProfiles/Project_Default.xml +5 -5
  10. data/.idea/media_types-serialization.iml +76 -76
  11. data/.idea/misc.xml +6 -6
  12. data/.idea/modules.xml +7 -7
  13. data/.idea/runConfigurations/test.xml +19 -19
  14. data/.idea/vcs.xml +5 -5
  15. data/CHANGELOG.md +207 -200
  16. data/CODE_OF_CONDUCT.md +74 -74
  17. data/Gemfile +4 -4
  18. data/Gemfile.lock +176 -169
  19. data/LICENSE.txt +21 -21
  20. data/README.md +1058 -1048
  21. data/Rakefile +10 -10
  22. data/bin/console +14 -14
  23. data/bin/setup +8 -8
  24. data/lib/media_types/problem.rb +67 -67
  25. data/lib/media_types/serialization/base.rb +269 -269
  26. data/lib/media_types/serialization/error.rb +193 -193
  27. data/lib/media_types/serialization/fake_validator.rb +53 -53
  28. data/lib/media_types/serialization/serialization_dsl.rb +139 -135
  29. data/lib/media_types/serialization/serialization_registration.rb +245 -245
  30. data/lib/media_types/serialization/serializers/api_viewer.rb +383 -383
  31. data/lib/media_types/serialization/serializers/common_css.rb +212 -212
  32. data/lib/media_types/serialization/serializers/endpoint_description_serializer.rb +80 -80
  33. data/lib/media_types/serialization/serializers/fallback_not_acceptable_serializer.rb +85 -85
  34. data/lib/media_types/serialization/serializers/fallback_unsupported_media_type_serializer.rb +58 -58
  35. data/lib/media_types/serialization/serializers/input_validation_error_serializer.rb +95 -93
  36. data/lib/media_types/serialization/serializers/problem_serializer.rb +111 -111
  37. data/lib/media_types/serialization/utils/accept_header.rb +77 -77
  38. data/lib/media_types/serialization/utils/accept_language_header.rb +82 -82
  39. data/lib/media_types/serialization/version.rb +7 -7
  40. data/lib/media_types/serialization.rb +689 -689
  41. data/media_types-serialization.gemspec +48 -48
  42. metadata +3 -3
data/Gemfile.lock CHANGED
@@ -1,169 +1,176 @@
1
- PATH
2
- remote: .
3
- specs:
4
- media_types-serialization (2.0.4)
5
- actionpack (>= 6.0.0)
6
- activesupport (>= 6.0.0)
7
- media_types (>= 2.2.3, < 3.0.0)
8
-
9
- GEM
10
- remote: https://rubygems.org/
11
- specs:
12
- actioncable (6.1.7.4)
13
- actionpack (= 6.1.7.4)
14
- activesupport (= 6.1.7.4)
15
- nio4r (~> 2.0)
16
- websocket-driver (>= 0.6.1)
17
- actionmailbox (6.1.7.4)
18
- actionpack (= 6.1.7.4)
19
- activejob (= 6.1.7.4)
20
- activerecord (= 6.1.7.4)
21
- activestorage (= 6.1.7.4)
22
- activesupport (= 6.1.7.4)
23
- mail (>= 2.7.1)
24
- actionmailer (6.1.7.4)
25
- actionpack (= 6.1.7.4)
26
- actionview (= 6.1.7.4)
27
- activejob (= 6.1.7.4)
28
- activesupport (= 6.1.7.4)
29
- mail (~> 2.5, >= 2.5.4)
30
- rails-dom-testing (~> 2.0)
31
- actionpack (6.1.7.4)
32
- actionview (= 6.1.7.4)
33
- activesupport (= 6.1.7.4)
34
- rack (~> 2.0, >= 2.0.9)
35
- rack-test (>= 0.6.3)
36
- rails-dom-testing (~> 2.0)
37
- rails-html-sanitizer (~> 1.0, >= 1.2.0)
38
- actiontext (6.1.7.4)
39
- actionpack (= 6.1.7.4)
40
- activerecord (= 6.1.7.4)
41
- activestorage (= 6.1.7.4)
42
- activesupport (= 6.1.7.4)
43
- nokogiri (>= 1.8.5)
44
- actionview (6.1.7.4)
45
- activesupport (= 6.1.7.4)
46
- builder (~> 3.1)
47
- erubi (~> 1.4)
48
- rails-dom-testing (~> 2.0)
49
- rails-html-sanitizer (~> 1.1, >= 1.2.0)
50
- activejob (6.1.7.4)
51
- activesupport (= 6.1.7.4)
52
- globalid (>= 0.3.6)
53
- activemodel (6.1.7.4)
54
- activesupport (= 6.1.7.4)
55
- activerecord (6.1.7.4)
56
- activemodel (= 6.1.7.4)
57
- activesupport (= 6.1.7.4)
58
- activestorage (6.1.7.4)
59
- actionpack (= 6.1.7.4)
60
- activejob (= 6.1.7.4)
61
- activerecord (= 6.1.7.4)
62
- activesupport (= 6.1.7.4)
63
- marcel (~> 1.0)
64
- mini_mime (>= 1.1.0)
65
- activesupport (6.1.7.4)
66
- concurrent-ruby (~> 1.0, >= 1.0.2)
67
- i18n (>= 1.6, < 2)
68
- minitest (>= 5.1)
69
- tzinfo (~> 2.0)
70
- zeitwerk (~> 2.3)
71
- awesome_print (1.9.2)
72
- builder (3.2.4)
73
- concurrent-ruby (1.2.2)
74
- crass (1.0.6)
75
- date (3.3.3)
76
- erubi (1.12.0)
77
- globalid (1.1.0)
78
- activesupport (>= 5.0)
79
- i18n (1.14.1)
80
- concurrent-ruby (~> 1.0)
81
- loofah (2.21.3)
82
- crass (~> 1.0.2)
83
- nokogiri (>= 1.12.0)
84
- mail (2.8.1)
85
- mini_mime (>= 0.1.1)
86
- net-imap
87
- net-pop
88
- net-smtp
89
- marcel (1.0.2)
90
- media_types (2.3.2)
91
- method_source (1.0.0)
92
- mini_mime (1.1.5)
93
- minitest (5.19.0)
94
- net-imap (0.3.7)
95
- date
96
- net-protocol
97
- net-pop (0.1.2)
98
- net-protocol
99
- net-protocol (0.2.1)
100
- timeout
101
- net-smtp (0.3.3)
102
- net-protocol
103
- nio4r (2.5.9)
104
- nokogiri (1.15.4-x64-mingw32)
105
- racc (~> 1.4)
106
- oj (3.16.0)
107
- racc (1.7.1)
108
- rack (2.2.8)
109
- rack-test (2.1.0)
110
- rack (>= 1.3)
111
- rails (6.1.7.4)
112
- actioncable (= 6.1.7.4)
113
- actionmailbox (= 6.1.7.4)
114
- actionmailer (= 6.1.7.4)
115
- actionpack (= 6.1.7.4)
116
- actiontext (= 6.1.7.4)
117
- actionview (= 6.1.7.4)
118
- activejob (= 6.1.7.4)
119
- activemodel (= 6.1.7.4)
120
- activerecord (= 6.1.7.4)
121
- activestorage (= 6.1.7.4)
122
- activesupport (= 6.1.7.4)
123
- bundler (>= 1.15.0)
124
- railties (= 6.1.7.4)
125
- sprockets-rails (>= 2.0.0)
126
- rails-dom-testing (2.2.0)
127
- activesupport (>= 5.0.0)
128
- minitest
129
- nokogiri (>= 1.6)
130
- rails-html-sanitizer (1.6.0)
131
- loofah (~> 2.21)
132
- nokogiri (~> 1.14)
133
- railties (6.1.7.4)
134
- actionpack (= 6.1.7.4)
135
- activesupport (= 6.1.7.4)
136
- method_source
137
- rake (>= 12.2)
138
- thor (~> 1.0)
139
- rake (13.0.6)
140
- sprockets (4.2.0)
141
- concurrent-ruby (~> 1.0)
142
- rack (>= 2.2.4, < 4)
143
- sprockets-rails (3.4.2)
144
- actionpack (>= 5.2)
145
- activesupport (>= 5.2)
146
- sprockets (>= 3.0.0)
147
- thor (1.2.2)
148
- timeout (0.4.0)
149
- tzinfo (2.0.6)
150
- concurrent-ruby (~> 1.0)
151
- websocket-driver (0.7.6)
152
- websocket-extensions (>= 0.1.0)
153
- websocket-extensions (0.1.5)
154
- zeitwerk (2.6.11)
155
-
156
- PLATFORMS
157
- x64-mingw32
158
-
159
- DEPENDENCIES
160
- awesome_print
161
- bundler
162
- media_types-serialization!
163
- minitest (~> 5.0)
164
- oj
165
- rails (~> 6.0)
166
- rake (~> 13.0)
167
-
168
- BUNDLED WITH
169
- 2.1.4
1
+ PATH
2
+ remote: .
3
+ specs:
4
+ media_types-serialization (2.1.0)
5
+ actionpack (>= 6.0.0)
6
+ activesupport (>= 6.0.0)
7
+ media_types (>= 2.2.3, < 3.0.0)
8
+
9
+ GEM
10
+ remote: https://rubygems.org/
11
+ specs:
12
+ actioncable (6.1.7.8)
13
+ actionpack (= 6.1.7.8)
14
+ activesupport (= 6.1.7.8)
15
+ nio4r (~> 2.0)
16
+ websocket-driver (>= 0.6.1)
17
+ actionmailbox (6.1.7.8)
18
+ actionpack (= 6.1.7.8)
19
+ activejob (= 6.1.7.8)
20
+ activerecord (= 6.1.7.8)
21
+ activestorage (= 6.1.7.8)
22
+ activesupport (= 6.1.7.8)
23
+ mail (>= 2.7.1)
24
+ actionmailer (6.1.7.8)
25
+ actionpack (= 6.1.7.8)
26
+ actionview (= 6.1.7.8)
27
+ activejob (= 6.1.7.8)
28
+ activesupport (= 6.1.7.8)
29
+ mail (~> 2.5, >= 2.5.4)
30
+ rails-dom-testing (~> 2.0)
31
+ actionpack (6.1.7.8)
32
+ actionview (= 6.1.7.8)
33
+ activesupport (= 6.1.7.8)
34
+ rack (~> 2.0, >= 2.0.9)
35
+ rack-test (>= 0.6.3)
36
+ rails-dom-testing (~> 2.0)
37
+ rails-html-sanitizer (~> 1.0, >= 1.2.0)
38
+ actiontext (6.1.7.8)
39
+ actionpack (= 6.1.7.8)
40
+ activerecord (= 6.1.7.8)
41
+ activestorage (= 6.1.7.8)
42
+ activesupport (= 6.1.7.8)
43
+ nokogiri (>= 1.8.5)
44
+ actionview (6.1.7.8)
45
+ activesupport (= 6.1.7.8)
46
+ builder (~> 3.1)
47
+ erubi (~> 1.4)
48
+ rails-dom-testing (~> 2.0)
49
+ rails-html-sanitizer (~> 1.1, >= 1.2.0)
50
+ activejob (6.1.7.8)
51
+ activesupport (= 6.1.7.8)
52
+ globalid (>= 0.3.6)
53
+ activemodel (6.1.7.8)
54
+ activesupport (= 6.1.7.8)
55
+ activerecord (6.1.7.8)
56
+ activemodel (= 6.1.7.8)
57
+ activesupport (= 6.1.7.8)
58
+ activestorage (6.1.7.8)
59
+ actionpack (= 6.1.7.8)
60
+ activejob (= 6.1.7.8)
61
+ activerecord (= 6.1.7.8)
62
+ activesupport (= 6.1.7.8)
63
+ marcel (~> 1.0)
64
+ mini_mime (>= 1.1.0)
65
+ activesupport (6.1.7.8)
66
+ concurrent-ruby (~> 1.0, >= 1.0.2)
67
+ i18n (>= 1.6, < 2)
68
+ minitest (>= 5.1)
69
+ tzinfo (~> 2.0)
70
+ zeitwerk (~> 2.3)
71
+ awesome_print (1.9.2)
72
+ bigdecimal (3.1.8)
73
+ builder (3.3.0)
74
+ concurrent-ruby (1.3.4)
75
+ crass (1.0.6)
76
+ date (3.3.4)
77
+ erubi (1.13.0)
78
+ globalid (1.2.1)
79
+ activesupport (>= 6.1)
80
+ i18n (1.14.5)
81
+ concurrent-ruby (~> 1.0)
82
+ loofah (2.22.0)
83
+ crass (~> 1.0.2)
84
+ nokogiri (>= 1.12.0)
85
+ mail (2.8.1)
86
+ mini_mime (>= 0.1.1)
87
+ net-imap
88
+ net-pop
89
+ net-smtp
90
+ marcel (1.0.4)
91
+ media_types (2.3.3.bookworm)
92
+ method_source (1.1.0)
93
+ mini_mime (1.1.5)
94
+ minitest (5.25.1)
95
+ net-imap (0.4.14)
96
+ date
97
+ net-protocol
98
+ net-pop (0.1.2)
99
+ net-protocol
100
+ net-protocol (0.2.2)
101
+ timeout
102
+ net-smtp (0.5.0)
103
+ net-protocol
104
+ nio4r (2.7.3)
105
+ nokogiri (1.16.7-x64-mingw32)
106
+ racc (~> 1.4)
107
+ nokogiri (1.16.7-x86_64-linux)
108
+ racc (~> 1.4)
109
+ oj (3.16.7)
110
+ bigdecimal (>= 3.0)
111
+ ostruct (>= 0.2)
112
+ ostruct (0.6.0)
113
+ racc (1.8.1)
114
+ rack (2.2.9)
115
+ rack-test (2.1.0)
116
+ rack (>= 1.3)
117
+ rails (6.1.7.8)
118
+ actioncable (= 6.1.7.8)
119
+ actionmailbox (= 6.1.7.8)
120
+ actionmailer (= 6.1.7.8)
121
+ actionpack (= 6.1.7.8)
122
+ actiontext (= 6.1.7.8)
123
+ actionview (= 6.1.7.8)
124
+ activejob (= 6.1.7.8)
125
+ activemodel (= 6.1.7.8)
126
+ activerecord (= 6.1.7.8)
127
+ activestorage (= 6.1.7.8)
128
+ activesupport (= 6.1.7.8)
129
+ bundler (>= 1.15.0)
130
+ railties (= 6.1.7.8)
131
+ sprockets-rails (>= 2.0.0)
132
+ rails-dom-testing (2.2.0)
133
+ activesupport (>= 5.0.0)
134
+ minitest
135
+ nokogiri (>= 1.6)
136
+ rails-html-sanitizer (1.6.0)
137
+ loofah (~> 2.21)
138
+ nokogiri (~> 1.14)
139
+ railties (6.1.7.8)
140
+ actionpack (= 6.1.7.8)
141
+ activesupport (= 6.1.7.8)
142
+ method_source
143
+ rake (>= 12.2)
144
+ thor (~> 1.0)
145
+ rake (13.2.1)
146
+ sprockets (4.2.1)
147
+ concurrent-ruby (~> 1.0)
148
+ rack (>= 2.2.4, < 4)
149
+ sprockets-rails (3.5.2)
150
+ actionpack (>= 6.1)
151
+ activesupport (>= 6.1)
152
+ sprockets (>= 3.0.0)
153
+ thor (1.3.1)
154
+ timeout (0.4.1)
155
+ tzinfo (2.0.6)
156
+ concurrent-ruby (~> 1.0)
157
+ websocket-driver (0.7.6)
158
+ websocket-extensions (>= 0.1.0)
159
+ websocket-extensions (0.1.5)
160
+ zeitwerk (2.6.17)
161
+
162
+ PLATFORMS
163
+ x64-mingw32
164
+ x86_64-linux
165
+
166
+ DEPENDENCIES
167
+ awesome_print
168
+ bundler
169
+ media_types-serialization!
170
+ minitest (~> 5.0)
171
+ oj
172
+ rails (~> 6.0)
173
+ rake (~> 13.0)
174
+
175
+ BUNDLED WITH
176
+ 2.3.15
data/LICENSE.txt CHANGED
@@ -1,21 +1,21 @@
1
- The MIT License (MIT)
2
-
3
- Copyright (c) 2019 Derk-Jan Karrenbeld
4
-
5
- Permission is hereby granted, free of charge, to any person obtaining a copy
6
- of this software and associated documentation files (the "Software"), to deal
7
- in the Software without restriction, including without limitation the rights
8
- to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
- copies of the Software, and to permit persons to whom the Software is
10
- furnished to do so, subject to the following conditions:
11
-
12
- The above copyright notice and this permission notice shall be included in
13
- all copies or substantial portions of the Software.
14
-
15
- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
- IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
- FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
- AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
- LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
- OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
21
- THE SOFTWARE.
1
+ The MIT License (MIT)
2
+
3
+ Copyright (c) 2019 Derk-Jan Karrenbeld
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ of this software and associated documentation files (the "Software"), to deal
7
+ in the Software without restriction, including without limitation the rights
8
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ copies of the Software, and to permit persons to whom the Software is
10
+ furnished to do so, subject to the following conditions:
11
+
12
+ The above copyright notice and this permission notice shall be included in
13
+ all copies or substantial portions of the Software.
14
+
15
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
21
+ THE SOFTWARE.