function testNews_modify_form()
 {
     global $text, $subject, $creation, $sess, $bx, $t;
     $text = "this is the text";
     $subject = "this is the subject";
     $creation = "asdasd";
     $proid = 'proid';
     $bx = $this->_create_default_box();
     capture_reset_and_start();
     news_modify_form($proid);
     $this->set_text(capture_stop_and_get());
     $this->_checkFor_a_box('Modifying News');
     $this->_checkFor_a_form('PHP_SELF', array('proid' => $proid));
     $this->_testFor_html_form_hidden('creation', $creation);
     $this->_checkFor_columns(2);
     $this->_checkFor_column_titles(array('Subject', 'Body'));
     $this->_checkFor_column_values(array(html_textarea('text', 40, 7, 'virtual', 255, $text), html_input_text('subject', 40, 128, $subject)));
     $this->_checkFor_submit_preview_buttons();
     $this->_testFor_string_length(2366 + strlen($sess->self_url()));
 }
page_open(array("sess" => "SourceAgency_Session"));
if (isset($auth) && !empty($auth->auth["perm"])) {
    page_close();
    page_open(array("sess" => "SourceAgency_Session", "auth" => "SourceAgency_Auth", "perm" => "SourceAgency_Perm"));
}
require "include/header.inc";
require "include/newslib.inc";
$bx = new box("80%", $th_box_frame_color, $th_box_frame_width, $th_box_title_bgcolor, $th_box_title_font_color, $th_box_title_align, $th_box_body_bgcolor, $th_box_body_font_color, $th_box_body_align);
$be = new box("80%", $th_box_frame_color, $th_box_frame_width, $th_box_title_bgcolor, $th_box_title_font_color, $th_box_title_align, $th_box_body_bgcolor, $th_box_error_font_color, $th_box_body_align);
$bs = new box("100%", $th_strip_frame_color, $th_strip_frame_width, $th_strip_title_bgcolor, $th_strip_title_font_color, $th_strip_title_align, $th_strip_body_bgcolor, $th_strip_body_font_color, $th_strip_body_align);
start_content();
$page = "news_mod";
if (check_proid($proid)) {
    top_bar($proid, $page);
    print $t->translate("News can be modified by the project owner(s)") . ".\n<br><p>\n";
    if ((!isset($preview) || empty($preview)) && (!isset($submit) || empty($submit))) {
        $db->query("SELECT * FROM news WHERE subject_news='First Comment!'");
        $db->next_record();
        $subject = $db->f("subject_news");
        $text = $db->f("text_news");
        $creation = $db->f("creation_news");
    }
    if (!isset($submit) || empty($submit)) {
        news_modify_form($proid);
    } else {
        news_modify($proid, "devel", $subject, $text, $creation);
    }
}
end_content();
require "include/footer.inc";
@page_close();