1. <strong id="7actg"></strong>
    2. <table id="7actg"></table>

    3. <address id="7actg"></address>
      <address id="7actg"></address>
      1. <object id="7actg"><tt id="7actg"></tt></object>

        SimpleTestPHP單元測試框架

        聯(lián)合創(chuàng)作 · 2023-10-01 16:06

        SimpleTest 是一個為PHP程序提供的單元測試的框架,包含一個內(nèi)嵌的web瀏覽器用來測試PHP的Web網(wǎng)站。

        示例代碼

         <?php
        require_once('simpletest/unit_tester.php');
        require_once('simpletest/reporter.php');
        require_once('../classes/log.php');

        class TestOfLogging extends UnitTestCase {

        function testCreatingNewFile() {
        @unlink('/temp/test.log');
        $log = new Log('/temp/test.log');
        $this->assertFalse(file_exists('/temp/test.log'));
        $log->message('Should write this to a file');
        $this->assertTrue(file_exists('/temp/test.log'));
        }
        }

        $test = &new TestOfLogging();
        $test->run(new HtmlReporter());

        ?>
        瀏覽 2
        點贊
        評論
        收藏
        分享

        手機掃一掃分享

        編輯 分享
        舉報
        評論
        圖片
        表情
        推薦
        點贊
        評論
        收藏
        分享

        手機掃一掃分享

        編輯 分享
        舉報
        1. <strong id="7actg"></strong>
        2. <table id="7actg"></table>

        3. <address id="7actg"></address>
          <address id="7actg"></address>
          1. <object id="7actg"><tt id="7actg"></tt></object>
            中文字幕aV一区二区三区 | 久久婷婷视频 | 色五月天在线视频 | 国产另类xxxx | 交女视频网站 | 亚洲最新AV网站 | 4399午夜理伦免费播放大全 | 欧美老熟妇乱子伦视频 | 欧美大屌在线 | 欧美一区二区三区特黄 |