dangreenisrael / eslint-plugin-jest-formatting

ESLint rules for formatting test suites written for jest.
MIT License
156 stars 13 forks source link

Blank line before expect #121

Open alina-kala4ik opened 8 months ago

alina-kala4ik commented 8 months ago

Blank line before expect or block of expects

Valid code example:

  it("test name", () => {
    const someVariable = "...";

    expect(someVariable).toBe(2);
    expect(someVariable).toBe(1);
  })

Invalid code example:

    it('test name', () => {
        const someVariable = '...';
        expect(someVariable).toBe('');
        expect(someVariable).toBe('');
    });