Commit 42e075a
test: improve performance of stringbytes test
String concatenation in the assert messages has drastic impact on test
runtime. Removal of these messages is unlikely to affect debugging if
any breaking changes are made.
Previous time to run:
$ time ./iojs test/parallel/test-stringbytes-external.js
real 0m2.321s
user 0m2.256s
sys 0m0.092s
With fix:
$ time ./iojs test/parallel/test-stringbytes-external.js
real 0m0.518s
user 0m0.508s
sys 0m0.008s
PR-URL: #2544
Reviewed-By: trevnorris - Trevor Norris <trev.norris@gmail.com>
Reviewed-By: thefourtheye - Sakthipriyan Vairamani <thechargingvolcano@gmail.com>1 parent 3172e9c commit 42e075aCopy full SHA for 42e075a
File tree
Expand file treeCollapse file tree
1 file changed
+5
-17
lines changedOpen diff view settings
Filter options
- test/parallel
Expand file treeCollapse file tree
1 file changed
+5
-17
lines changedOpen diff view settings
Collapse file
test/parallel/test-stringbytes-external.js
Copy file name to clipboardExpand all lines: test/parallel/test-stringbytes-external.js+5-17Lines changed: 5 additions & 17 deletions
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| ||
40 | 40 | |
41 | 41 | |
42 | 42 | |
43 | | - |
44 | | - |
| 43 | + |
45 | 44 | |
46 | 45 | |
47 | 46 | |
| ||
63 | 62 | |
64 | 63 | |
65 | 64 | |
66 | | - |
67 | | - |
68 | | - |
69 | 65 | |
70 | 66 | |
71 | | - |
72 | | - |
| 67 | + |
73 | 68 | |
74 | 69 | |
75 | 70 | |
76 | 71 | |
77 | | - |
78 | | - |
| 72 | + |
79 | 73 | |
80 | 74 | |
81 | 75 | |
| ||
89 | 83 | |
90 | 84 | |
91 | 85 | |
92 | | - |
93 | | - |
94 | | - |
95 | 86 | |
96 | 87 | |
97 | | - |
98 | | - |
99 | | - |
| 88 | + |
100 | 89 | |
101 | 90 | |
102 | 91 | |
103 | 92 | |
104 | | - |
105 | | - |
| 93 | + |
106 | 94 | |
107 | 95 | |
108 | 96 | |
|
0 commit comments