zoe             Mon Apr 27 21:05:54 2009 UTC

  Added files:                 
    /phpruntests/src/testcase/sections/configurationsections    
                                                                
rtPostSection.php 

  Modified files:              
    /phpruntests/src/testcase/sections/configurationsections    
                                                                
rtGetSection.php 
  Log:
  Start of POST implementation
  
http://cvs.php.net/viewvc.cgi/phpruntests/src/testcase/sections/configurationsections/rtGetSection.php?r1=1.2&r2=1.3&diff_format=u
Index: phpruntests/src/testcase/sections/configurationsections/rtGetSection.php
diff -u 
phpruntests/src/testcase/sections/configurationsections/rtGetSection.php:1.2 
phpruntests/src/testcase/sections/configurationsections/rtGetSection.php:1.3
--- 
phpruntests/src/testcase/sections/configurationsections/rtGetSection.php:1.2    
    Sun Apr 26 22:44:23 2009
+++ phpruntests/src/testcase/sections/configurationsections/rtGetSection.php    
Mon Apr 27 21:05:54 2009
@@ -1,17 +1,6 @@
 <?php
 /**
  * rtGetSection
- *
- * @category  Testing
- * @package   RUNTESTS
- * @author    Zoe Slattery <z...@php.net>
- * @author    Stefan Priebsch <sprieb...@php.net>
- * @copyright 2009 The PHP Group
- * @license   http://www.php.net/license/3_01.txt PHP License 3.01
- * @link      http://qa.php.net/
- */
-
-/**
  * Sets environment variables for GET section
  *
  *

http://cvs.php.net/viewvc.cgi/phpruntests/src/testcase/sections/configurationsections/rtPostSection.php?view=markup&rev=1.1
Index: phpruntests/src/testcase/sections/configurationsections/rtPostSection.php
+++ phpruntests/src/testcase/sections/configurationsections/rtPostSection.php
<?php
/**
 * rtPostSection
 * Sets environment variables for GET section
 *
 *
 * @category  Testing
 * @package   RUNTESTS
 * @author    Zoe Slattery <z...@php.net>
 * @author    Stefan Priebsch <sprieb...@php.net>
 * @copyright 2009 The PHP Group
 * @license   http://www.php.net/license/3_01.txt PHP License 3.01
 * @link      http://qa.php.net/
 */
class rtPostSection extends rtConfigurationSection
{
    private $postVariables = array();
    private $postFileName;

    protected function init()
    {
        $this->postVariables['CONTENT_TYPE'] = 
'application/x-www-form-urlencoded';
        $this->postVariables['REQUEST_METHOD'] = 'POST';

        $postString = implode('\n', $this->sectionContents);
        $this->postFileName = tempnam(sys_get_temp_dir(), 'post');
        file_put_contents($this->postFileName, $postString);
    }

    /**
     * Additional GET environment variables required by the test
     *
     * @return array
     */
    public function getPostVariables()
    {
        return $this->postVariables;
    }

    public function getPostFileName()
    {
        return $this->postFileName;
    }
}
?>


-- 
PHP CVS Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php

Reply via email to