---
source: crates/oxc_linter/src/tester.rs
---
  ⚠ eslint-plugin-jest(prefer-hooks-on-top): Suggest having hooks before any test cases.
   ╭─[prefer_hooks_on_top.tsx:8:21]
 7 │ 
 8 │                     beforeAll(() => {});
   ·                     ───────────────────
 9 │                     test('bar', () => {
   ╰────
  help: Hooks should come before test cases

  ⚠ eslint-plugin-jest(prefer-hooks-on-top): Suggest having hooks before any test cases.
   ╭─[prefer_hooks_on_top.tsx:8:21]
 7 │ 
 8 │                     beforeAll(() => {});
   ·                     ───────────────────
 9 │                     test.only('bar', () => {
   ╰────
  help: Hooks should come before test cases

  ⚠ eslint-plugin-jest(prefer-hooks-on-top): Suggest having hooks before any test cases.
   ╭─[prefer_hooks_on_top.tsx:8:21]
 7 │ 
 8 │                     beforeAll(() => {});
   ·                     ───────────────────
 9 │                     test.only('bar', () => {
   ╰────
  help: Hooks should come before test cases

  ⚠ eslint-plugin-jest(prefer-hooks-on-top): Suggest having hooks before any test cases.
   ╭─[prefer_hooks_on_top.tsx:8:21]
 7 │ 
 8 │                     beforeAll(() => {});
   ·                     ───────────────────
 9 │                     test('bar', () => {
   ╰────
  help: Hooks should come before test cases

  ⚠ eslint-plugin-jest(prefer-hooks-on-top): Suggest having hooks before any test cases.
    ╭─[prefer_hooks_on_top.tsx:28:21]
 27 │ 
 28 │                     beforeEach(() => {});
    ·                     ────────────────────
 29 │                     beforeEach(() => {});
    ╰────
  help: Hooks should come before test cases

  ⚠ eslint-plugin-jest(prefer-hooks-on-top): Suggest having hooks before any test cases.
    ╭─[prefer_hooks_on_top.tsx:29:21]
 28 │                     beforeEach(() => {});
 29 │                     beforeEach(() => {});
    ·                     ────────────────────
 30 │                     beforeAll(() => {});
    ╰────
  help: Hooks should come before test cases

  ⚠ eslint-plugin-jest(prefer-hooks-on-top): Suggest having hooks before any test cases.
    ╭─[prefer_hooks_on_top.tsx:30:21]
 29 │                     beforeEach(() => {});
 30 │                     beforeAll(() => {});
    ·                     ───────────────────
 31 │                 });
    ╰────
  help: Hooks should come before test cases

  ⚠ eslint-plugin-jest(prefer-hooks-on-top): Suggest having hooks before any test cases.
    ╭─[prefer_hooks_on_top.tsx:18:25]
 17 │ 
 18 │                         beforeAll(() => {});
    ·                         ───────────────────
 19 │                         afterAll(() => {});
    ╰────
  help: Hooks should come before test cases

  ⚠ eslint-plugin-jest(prefer-hooks-on-top): Suggest having hooks before any test cases.
    ╭─[prefer_hooks_on_top.tsx:19:25]
 18 │                         beforeAll(() => {});
 19 │                         afterAll(() => {});
    ·                         ──────────────────
 20 │                         test('inner bar', () => {
    ╰────
  help: Hooks should come before test cases
