mswjs / data

Data modeling and relation library for testing JavaScript applications.

Home Page:https://npm.im/@mswjs/data

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Decide on performance testing

kettanaito opened this issue · comments

The current state of the performance testing is left to be desired.

FAIL test/performance/performance.test.ts
  ● creates a 1000 records in under 100ms

    expect(received).toBeLessThanOrEqual(expected)

    Expected: <= 350
    Received:    565.461743

      18 |   })
      19 | 
    > 20 |   expect(createPerformance.duration).toBeLessThanOrEqual(350)

I like the intention to have some performance regression metrics, but as long as it's reliable. If there's no way to make it such, I'd much prefer these tests to be removed (or skipped).

I'd much prefer performance tests to report in a separate thread to visually see how certain changes affect performance. There is no need to automatically fail the build, as in not treat performance results as any subject to passing/failing a test.