當前位置: 首頁>>代碼示例>>PHP>>正文


PHP test_end函數代碼示例

本文整理匯總了PHP中test_end函數的典型用法代碼示例。如果您正苦於以下問題:PHP test_end函數的具體用法?PHP test_end怎麽用?PHP test_end使用的例子?那麽, 這裏精選的函數代碼示例或許可以為您提供幫助。


在下文中一共展示了test_end函數的15個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的PHP代碼示例。

示例1: test_global_scalar_assign

function test_global_scalar_assign($base)
{
    $t = $base;
    test_start(__FUNCTION__);
    global $a, $b, $c, $d, $e, $f, $g, $h;
    global $i, $j, $k, $l, $m, $n, $o, $p;
    do {
        $a = 1;
        $b = $a;
        $c = $a + $b;
        $d = $c - $a;
        $e = $a + $c - $d - $b;
        $f = $a | $c;
        $g = $b & $d;
        $h = $a ^ $b ^ $c ^ $d ^ $e ^ $f ^ $g;
        $i = $a;
        $j = $b;
        $k = $c;
        $l = $d;
        $m = $e;
        $n = $f;
        $o = $g;
        $p = $h;
    } while (--$t !== 0);
    return test_end(__FUNCTION__);
}
開發者ID:michaelprem,項目名稱:phc,代碼行數:26,代碼來源:test_global_scalar_assign.php

示例2: test_local_float_assign

function test_local_float_assign($base)
{
    $t = $base;
    test_start(__FUNCTION__);
    do {
        $a = 6.42;
        $b = 9.42;
        $c = 42.42;
        $d = 69.42;
        $e = 4242.42;
        $f = 17.42;
        $g = 3200000.42;
        $h = -3200000.42;
        $i = $a;
        $j = $b;
        $k = $c;
        $l = $d;
        $m = $e;
        $n = $f;
        $o = $g;
        $p = $h;
    } while (--$t !== 0);
    if (!is_float($a) || $g + $h !== 0.0) {
        test_regression(__FUNCTION__);
    }
    return test_end(__FUNCTION__);
}
開發者ID:michaelprem,項目名稱:phc,代碼行數:27,代碼來源:test_local_float_assign.php

示例3: test_local_scalar_assign

function test_local_scalar_assign($base)
{
    $t = $base;
    test_start(__FUNCTION__);
    do {
        $a = 1;
        $b = $a;
        $c = $a + $b;
        $d = $c - $a;
        $e = $a + $c - $d - $b;
        $f = $a | $c;
        $g = $b & $d;
        $h = $a ^ $b ^ $c ^ $d ^ $e ^ $f ^ $g;
        $i = $a;
        $j = $b;
        $k = $c;
        $l = $d;
        $m = $e;
        $n = $f;
        $o = $g;
        $p = $h;
    } while (--$t !== 0);
    if (md5($a . $b . $c . $d . $e . $f . $g . $h . $i . $j . $k . $l . $m . $n . $o . $p) !== 'efe1603e8bbb8403b6bfe7a43a39ade1') {
        test_regression(__FUNCTION__);
    }
    return test_end(__FUNCTION__);
}
開發者ID:michaelprem,項目名稱:phc,代碼行數:27,代碼來源:test_local_scalar_assign.php

示例4: test_local_integer_assign

function test_local_integer_assign($base)
{
    $t = $base;
    test_start(__FUNCTION__);
    do {
        $a = 6;
        $b = 9;
        $c = 42;
        $d = 69;
        $e = 4242;
        $f = 17;
        $g = 3200000;
        $h = -3200000;
        $i = $a;
        $j = $b;
        $k = $c;
        $l = $d;
        $m = $e;
        $n = $f;
        $o = $g;
        $p = $h;
    } while (--$t !== 0);
    if ($g + $h !== 0) {
        test_regression(__FUNCTION__);
    }
    return test_end(__FUNCTION__);
}
開發者ID:michaelprem,項目名稱:phc,代碼行數:27,代碼來源:test_local_integer_assign.php

示例5: test_global_string_assign

function test_global_string_assign($base)
{
    $t = $base;
    test_start(__FUNCTION__);
    global $a, $b, $c, $d, $e, $f, $g, $h;
    global $i, $j, $k, $l, $m, $n, $o, $p;
    do {
        $a = 'abcdefghijklmnop';
        $b = $a;
        $c = $a . $b;
        $d = $c . $a;
        $e = $a . $c . $d . $b;
        $f = $a . $c;
        $g = $b . $d;
        $h = $a . $b . $c . $d . $e . $f . $g;
        $i = $a;
        $j = $b;
        $k = $c;
        $l = $d;
        $m = $e;
        $n = $f;
        $o = $g;
        $p = $h;
    } while (--$t !== 0);
    return test_end(__FUNCTION__);
}
開發者ID:michaelprem,項目名稱:phc,代碼行數:26,代碼來源:test_global_string_assign.php

示例6: test_local_string_assign

function test_local_string_assign($base)
{
    $t = $base;
    test_start(__FUNCTION__);
    do {
        $a = 'abcdefghijklmnop';
        $b = $a;
        $c = $a . $b;
        $d = $c . $a;
        $e = $a . $c . $d . $b;
        $f = $a . $c;
        $g = $b . $d;
        $h = $a . $b . $c . $d . $e . $f . $g;
        $i = $a;
        $j = $b;
        $k = $c;
        $l = $d;
        $m = $e;
        $n = $f;
        $o = $g;
        $p = $h;
    } while (--$t !== 0);
    if (md5($a . $b . $c . $d . $e . $f . $g . $h . $i . $j . $k . $l . $m . $n . $o . $p) !== '12d5479a566db15ec0028b9cf242d150') {
        test_regression(__FUNCTION__);
    }
    return test_end(__FUNCTION__);
}
開發者ID:michaelprem,項目名稱:phc,代碼行數:27,代碼來源:test_local_string_assign.php

示例7: test_empty_loop

function test_empty_loop($base)
{
    $t = $base * 30;
    test_start(__FUNCTION__);
    do {
    } while (--$t !== 0);
    return test_end(__FUNCTION__);
}
開發者ID:michaelprem,項目名稱:phc,代碼行數:8,代碼來源:test_empty_loop.php

示例8: test_mt_rand

function test_mt_rand($base)
{
    $t = $base;
    test_start(__FUNCTION__);
    do {
        if (mt_rand(1, 255) <= 0) {
            test_regression(__FUNCTION__);
        }
    } while (--$t !== 0);
    return test_end(__FUNCTION__);
}
開發者ID:michaelprem,項目名稱:phc,代碼行數:11,代碼來源:test_mt_rand.php

示例9: test_md5

function test_md5($base)
{
    $t = $base;
    test_start(__FUNCTION__);
    do {
        if (md5($t) == '') {
            test_regression(__FUNCTION__);
        }
    } while (--$t !== 0);
    return test_end(__FUNCTION__);
}
開發者ID:michaelprem,項目名稱:phc,代碼行數:11,代碼來源:test_md5.php

示例10: test_compare_invert

function test_compare_invert($base)
{
    $a = array(42);
    $t = $base;
    test_start(__FUNCTION__);
    do {
        if (!$a) {
            test_regression(__FUNCTION__);
        }
    } while (--$t !== 0);
    return test_end(__FUNCTION__);
}
開發者ID:michaelprem,項目名稱:phc,代碼行數:12,代碼來源:test_compare_invert.php

示例11: test_compare_false

function test_compare_false($base)
{
    $a = array(42);
    $t = $base;
    test_start(__FUNCTION__);
    do {
        if ($a === FALSE) {
            test_regression(__FUNCTION__);
        }
    } while (--$t !== 0);
    return test_end(__FUNCTION__);
}
開發者ID:michaelprem,項目名稱:phc,代碼行數:12,代碼來源:test_compare_false.php

示例12: test_time

function test_time($base)
{
    $t = $base;
    test_start(__FUNCTION__);
    do {
        $a = time();
        if (time() < $a) {
            test_regression(__FUNCTION__);
        }
    } while (--$t !== 0);
    return test_end(__FUNCTION__);
}
開發者ID:michaelprem,項目名稱:phc,代碼行數:12,代碼來源:test_time.php

示例13: test_empty

function test_empty($base)
{
    $a = str_repeat('xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx', 1000);
    $t = $base;
    test_start(__FUNCTION__);
    do {
        if (empty($a)) {
            test_regression(__FUNCTION__);
        }
    } while (--$t !== 0);
    return test_end(__FUNCTION__);
}
開發者ID:michaelprem,項目名稱:phc,代碼行數:12,代碼來源:test_empty.php

示例14: test_local_object_assign

function test_local_object_assign($base)
{
    $t = $base;
    test_start(__FUNCTION__);
    do {
        $a = new TestLocalObjectAssign();
    } while (--$t !== 0);
    if (!is_object($a) || $a->ok() !== TRUE) {
        test_regression(__FUNCTION__);
    }
    return test_end(__FUNCTION__);
}
開發者ID:michaelprem,項目名稱:phc,代碼行數:12,代碼來源:test_local_object_assign.php

示例15: test_while

function test_while($base)
{
    $t = (int) round($base / 10);
    test_start(__FUNCTION__);
    do {
        $d = 1000;
        while ($d !== 0) {
            $d--;
        }
    } while (--$t !== 0);
    return test_end(__FUNCTION__);
}
開發者ID:michaelprem,項目名稱:phc,代碼行數:12,代碼來源:test_while.php


注:本文中的test_end函數示例由純淨天空整理自Github/MSDocs等開源代碼及文檔管理平台,相關代碼片段篩選自各路編程大神貢獻的開源項目,源碼版權歸原作者所有,傳播和使用請參考對應項目的License;未經允許,請勿轉載。