We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
2 parents b391224 + 1628244 commit d22054aCopy full SHA for d22054a
lib/jsonapi_compliable/version.rb
@@ -1,3 +1,3 @@
1
module JsonapiCompliable
2
- VERSION = "0.3.8"
+ VERSION = "0.3.9"
3
end
spec/stats_spec.rb
@@ -169,4 +169,12 @@ def index
169
expect(json['meta']['stats']).to eq({ 'total' => { 'count' => 1 } })
170
171
172
+
173
+ context 'when requested stat not configured' do
174
+ it 'raises error' do
175
+ expect {
176
+ get :index, params: { stats: { asdf: :count} }
177
+ }.to raise_error(JsonapiCompliable::Errors::StatNotFound, "No stat configured for calculation :count on attribute 'asdf'")
178
+ end
179
180
0 commit comments