Skip to content

Commit

Permalink
chore(utils): remove deprecated property
Browse files Browse the repository at this point in the history
  • Loading branch information
G-Rath committed Aug 6, 2019
1 parent 9e807aa commit ed51d41
Showing 1 changed file with 4 additions and 7 deletions.
11 changes: 4 additions & 7 deletions src/rules/utils.ts
Original file line number Diff line number Diff line change
Expand Up @@ -369,8 +369,6 @@ type ParsedExpectModifier =

interface Expectation<ExpectNode extends ExpectCall = ValidExpectCall> {
expect: ExpectNode;
/** @deprecated */
expectCall: ExpectNode;
modifier?: ParsedExpectModifier;
matcher?: ParsedExpectMatcher;
}
Expand Down Expand Up @@ -460,18 +458,17 @@ const shouldBeParsedExpectModifier = (
ModifierName.hasOwnProperty(member.name);

export const parseExpectCall = <ExpectNode extends ExpectCall>(
expectCall: ExpectNode,
expect: ExpectNode,
): Expectation<ExpectNode> => {
const expectation: Expectation<ExpectNode> = {
expect: expectCall,
expectCall,
expect,
};

if (!isExpectMember(expectCall.parent)) {
if (!isExpectMember(expect.parent)) {
return expectation;
}

const parsedMember = parseExpectMember(expectCall.parent);
const parsedMember = parseExpectMember(expect.parent);
if (!shouldBeParsedExpectModifier(parsedMember)) {
expectation.matcher = reparseAsMatcher(parsedMember);

Expand Down

0 comments on commit ed51d41

Please sign in to comment.