repeat test 5 times for better stability
This commit is contained in:
+12
-3
@@ -12,20 +12,21 @@
|
|||||||
# See the License for the specific language governing permissions and
|
# See the License for the specific language governing permissions and
|
||||||
# limitations under the License.
|
# limitations under the License.
|
||||||
|
|
||||||
#!/bin/bash
|
#!/bin/bash +x
|
||||||
|
|
||||||
JERRY=$1
|
JERRY=$1
|
||||||
TEST=$2
|
TEST=$2
|
||||||
RAW_OUTPUT=$3
|
RAW_OUTPUT=$3
|
||||||
SLEEP=0.3
|
SLEEP=0.3
|
||||||
|
REPEATS=5
|
||||||
|
|
||||||
RSS_OUTPUT=
|
RSS_OUTPUT=
|
||||||
PSS_OUTPUT=
|
PSS_OUTPUT=
|
||||||
SHARE_OUTPUT=
|
SHARE_OUTPUT=
|
||||||
RSS_SHARE_OUTPUT=
|
RSS_SHARE_OUTPUT=
|
||||||
|
|
||||||
START=$(date +%s.%N)
|
function run_test()
|
||||||
|
{
|
||||||
$JERRY $TEST &
|
$JERRY $TEST &
|
||||||
PID=$!
|
PID=$!
|
||||||
|
|
||||||
@@ -50,6 +51,14 @@ SHARE_OUTPUT="$SHARE_OUTPUT $SHARE_SUM\n"
|
|||||||
RSS_SHARE_OUTPUT="$RSS_SHARE_OUTPUT $RSS_SHARE_SUM\n"
|
RSS_SHARE_OUTPUT="$RSS_SHARE_OUTPUT $RSS_SHARE_SUM\n"
|
||||||
|
|
||||||
done
|
done
|
||||||
|
}
|
||||||
|
|
||||||
|
START=$(date +%s.%N)
|
||||||
|
|
||||||
|
for i in 1 2 3 4 5
|
||||||
|
do
|
||||||
|
run_test
|
||||||
|
done
|
||||||
|
|
||||||
FINISH=$(date +%s.%N)
|
FINISH=$(date +%s.%N)
|
||||||
EXEC_TIME=$(echo "$FINISH - $START" | bc)
|
EXEC_TIME=$(echo "$FINISH - $START" | bc)
|
||||||
|
|||||||
Reference in New Issue
Block a user