Skip to content

Commit

Permalink
Fix issue with comparing errors in dataMasking
Browse files Browse the repository at this point in the history
  • Loading branch information
jerelmiller committed Aug 16, 2024
1 parent c1f2578 commit 11d5f9a
Showing 1 changed file with 3 additions and 8 deletions.
11 changes: 3 additions & 8 deletions src/__tests__/dataMasking.ts
Original file line number Diff line number Diff line change
@@ -1,8 +1,7 @@
import { FragmentSpreadNode, GraphQLError, Kind, visit } from "graphql";
import { FragmentSpreadNode, Kind, visit } from "graphql";
import {
ApolloCache,
ApolloClient,
ApolloError,
Cache,
DataProxy,
DocumentTransform,
Expand Down Expand Up @@ -888,7 +887,7 @@ test("masks partial data returned from data on errors with errorPolicy `all`", a
age: 34,
},
},
errors: [new GraphQLError("Couldn't get name")],
errors: [{ message: "Couldn't get name" }],
},
delay: 20,
},
Expand All @@ -915,11 +914,7 @@ test("masks partial data returned from data on errors with errorPolicy `all`", a
},
});

expect(errors).toEqual([
new ApolloError({
graphQLErrors: [new GraphQLError("Couldn't get name")],
}),
]);
expect(errors).toEqual([{ message: "Couldn't get name" }]);
}
});

Expand Down

0 comments on commit 11d5f9a

Please sign in to comment.