@@ -1803,8 +1803,7 @@ describe('cacheReducer', () => {
1803
1803
expect ( pass3 . cache . databaseOverrides [ collection ] ) . to . eql ( ) ;
1804
1804
} ) ;
1805
1805
} ) ;
1806
-
1807
- describe ( 'Speed test' , ( ) => {
1806
+ describe ( 'Speed test (on 2015 Dual-core 1.5Ghz i5 w/ 8GB 1600 DDR3)' , ( ) => {
1808
1807
let namespaces ;
1809
1808
before ( ( ) => {
1810
1809
namespaces = debug . disable ( ) ;
@@ -1813,7 +1812,7 @@ describe('cacheReducer', () => {
1813
1812
if ( namespaces ) debug . enable ( namespaces ) ;
1814
1813
} ) ;
1815
1814
1816
- it ( '<16ms processing large action and large state' , async function ( ) {
1815
+ it ( '<36ms processing large action and large state' , async function ( ) {
1817
1816
// eslint-disable-next-line no-invalid-this
1818
1817
this . timeout ( 5_000 ) ;
1819
1818
@@ -1822,13 +1821,14 @@ describe('cacheReducer', () => {
1822
1821
await benchmark . record (
1823
1822
( ) => manyActions . forEach ( ( action ) => reducer ( appState , action ) ) ,
1824
1823
{
1825
- iterations : 20 ,
1826
- meanUnder : 20 ,
1824
+ iterations : 90 ,
1825
+ meanUnder : 36 ,
1826
+ standardDeviationUnder : 10 ,
1827
1827
} ,
1828
1828
) ;
1829
1829
} ) ;
1830
1830
1831
- it ( '<16ms to process stores 2,000 docs' , async function ( ) {
1831
+ it ( '<18ms to process stores 2,000 docs' , async function ( ) {
1832
1832
// eslint-disable-next-line no-invalid-this
1833
1833
this . timeout ( 5_000 ) ;
1834
1834
@@ -1852,11 +1852,11 @@ describe('cacheReducer', () => {
1852
1852
1853
1853
await benchmark . record ( ( ) => reducer ( appState , action ) , {
1854
1854
iterations : 50 ,
1855
- meanUnder : 16 ,
1855
+ meanUnder : 18 ,
1856
1856
} ) ;
1857
1857
} ) ;
1858
1858
1859
- it ( '<16ms to process 100 mutates' , async function ( ) {
1859
+ it ( '<24ms to process 100 mutates' , async function ( ) {
1860
1860
// eslint-disable-next-line no-invalid-this
1861
1861
this . timeout ( 5_000 ) ;
1862
1862
@@ -1879,19 +1879,19 @@ describe('cacheReducer', () => {
1879
1879
await benchmark . record (
1880
1880
( ) => manyActions . forEach ( ( action ) => reducer ( appState , action ) ) ,
1881
1881
{
1882
- iterations : 50 ,
1883
- meanUnder : 16 ,
1882
+ iterations : 125 ,
1883
+ meanUnder : 24 ,
1884
1884
} ,
1885
1885
) ;
1886
1886
} ) ;
1887
1887
1888
- it ( '<2ms to process 1MB action' , async function ( ) {
1888
+ it ( '<4ms to process 1MB action' , async function ( ) {
1889
1889
// eslint-disable-next-line no-invalid-this
1890
1890
this . timeout ( 5_000 ) ;
1891
1891
1892
1892
await benchmark . record ( ( ) => reducer ( primedState , largeAction ) , {
1893
- iterations : 50 ,
1894
- meanUnder : 2 ,
1893
+ iterations : 1_000 ,
1894
+ meanUnder : 4 ,
1895
1895
} ) ;
1896
1896
} ) ;
1897
1897
} ) ;
0 commit comments