Skip to content

Commit d56f77f

Browse files
author
Lee Richmond
committed
fix specs
1 parent a4b03fa commit d56f77f

File tree

1 file changed

+10
-0
lines changed

1 file changed

+10
-0
lines changed

spec/serializers/validation_serializer_spec.rb

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -26,6 +26,8 @@
2626
expect(subject).to eq(
2727
[
2828
{
29+
code: 'unprocessable_entity',
30+
status: '422',
2931
title: "Validation Error",
3032
detail: "Username can't be blank",
3133
source: { pointer: '/data/attributes/username' },
@@ -46,6 +48,8 @@
4648
expect(subject).to eq(
4749
[
4850
{
51+
code: 'unprocessable_entity',
52+
status: '422',
4953
title: 'Validation Error',
5054
detail: 'Pets is invalid',
5155
source: { pointer: '/data/relationships/pets' },
@@ -65,6 +69,8 @@
6569
expect(subject).to eq(
6670
[
6771
{
72+
code: 'unprocessable_entity',
73+
status: '422',
6874
title: 'Validation Error',
6975
detail: 'Pets is invalid',
7076
source: { pointer: '/data/attributes/pets' },
@@ -83,6 +89,8 @@
8389
expect(subject).to eq(
8490
[
8591
{
92+
code: 'unprocessable_entity',
93+
status: '422',
8694
title: 'Validation Error',
8795
detail: 'Pets is invalid',
8896
source: { pointer: '/data/relationships/pets' },
@@ -106,6 +114,8 @@
106114
expect(subject).to eq(
107115
[
108116
{
117+
code: 'unprocessable_entity',
118+
status: '422',
109119
title: 'Validation Error',
110120
detail: 'Foo.bar is invalid',
111121
source: { pointer: '/data/relationships/foo.bar' },

0 commit comments

Comments
 (0)