[limb-svn] r5532 - in 3.x/trunk/limb/web_app: src/command src/controller src/fetcher src/template/tags/fetch src/toolkit src/validation tests/cases/db/validation tests/cases/plain/fetcher tests/cases/plain/template/tags/fetch

svn at limb-project.com svn at limb-project.com
Thu Apr 5 14:31:47 MSD 2007


Author: pachanga
Date: 2007-04-05 14:31:47 +0400 (Thu, 05 Apr 2007)
New Revision: 5532
URL: http://fisheye.limb-project.com/changelog/limb/?cs=5532

Removed:
   3.x/trunk/limb/web_app/src/fetcher/lmbMessageBoxErrorsFetcher.class.php
   3.x/trunk/limb/web_app/src/fetcher/lmbMessageBoxMessagesFetcher.class.php
   3.x/trunk/limb/web_app/src/template/tags/fetch/message_box.tag.php
   3.x/trunk/limb/web_app/src/validation/lmbWebAppErrorList.class.php
   3.x/trunk/limb/web_app/tests/cases/db/validation/lmbWebAppErrorListTest.class.php
   3.x/trunk/limb/web_app/tests/cases/plain/fetcher/lmbMessageBoxErrorsFetcherTest.class.php
   3.x/trunk/limb/web_app/tests/cases/plain/fetcher/lmbMessageBoxMessagesFetcherTest.class.php
   3.x/trunk/limb/web_app/tests/cases/plain/template/tags/fetch/lmbMessageBoxTagTest.class.php
Modified:
   3.x/trunk/limb/web_app/src/command/lmbFormCommand.class.php
   3.x/trunk/limb/web_app/src/controller/lmbController.class.php
   3.x/trunk/limb/web_app/src/fetcher/lmbFlashBoxErrorsFetcher.class.php
   3.x/trunk/limb/web_app/src/fetcher/lmbFlashBoxFetcher.class.php
   3.x/trunk/limb/web_app/src/fetcher/lmbFlashBoxMessagesFetcher.class.php
   3.x/trunk/limb/web_app/src/toolkit/lmbWebAppTools.class.php
   3.x/trunk/limb/web_app/tests/cases/plain/fetcher/lmbFlashBoxErrorsFetcherTest.class.php
   3.x/trunk/limb/web_app/tests/cases/plain/fetcher/lmbFlashBoxFetcherTest.class.php
   3.x/trunk/limb/web_app/tests/cases/plain/fetcher/lmbFlashBoxMessagesFetcherTest.class.php
   3.x/trunk/limb/web_app/tests/cases/plain/template/tags/fetch/lmbFlashBoxTagTest.class.php
Log:
-- message box obsolete stuff removed, use flash box facility instead
-- lmbWebAppErrorList removed
-- flash box fills 'message' property, 'text' property is still here for BC

Modified: 3.x/trunk/limb/web_app/src/command/lmbFormCommand.class.php
===================================================================
--- 3.x/trunk/limb/web_app/src/command/lmbFormCommand.class.php	2007-04-05 09:55:30 UTC (rev 5531)
+++ 3.x/trunk/limb/web_app/src/command/lmbFormCommand.class.php	2007-04-05 10:31:47 UTC (rev 5532)
@@ -10,8 +10,8 @@
  * @package    web_app
  */
 lmb_require('limb/web_app/src/command/lmbActionCommand.class.php');
-lmb_require('limb/web_app/src/validation/lmbWebAppErrorList.class.php');
 lmb_require('limb/validation/src/lmbValidator.class.php');
+lmb_require('limb/validation/src/lmbErrorList.class.php');
 lmb_require('limb/core/src/exception/lmbDelegateHaltException.class.php');
 lmb_require('limb/classkit/src/lmbDelegate.class.php');
 
@@ -40,7 +40,7 @@
     else
       $this->form_id = $this->_guessFormId();
 
-    $this->error_list = new lmbWebAppErrorList();
+    $this->error_list = new lmbErrorList();
     $this->validator = $validator ? $validator : new lmbValidator($this->error_list);
   }
 

Modified: 3.x/trunk/limb/web_app/src/controller/lmbController.class.php
===================================================================
--- 3.x/trunk/limb/web_app/src/controller/lmbController.class.php	2007-04-05 09:55:30 UTC (rev 5531)
+++ 3.x/trunk/limb/web_app/src/controller/lmbController.class.php	2007-04-05 10:31:47 UTC (rev 5532)
@@ -10,7 +10,7 @@
  * @package    web_app
  */
 lmb_require('limb/web_app/src/controller/lmbAbstractController.class.php');
-lmb_require('limb/web_app/src/validation/lmbWebAppErrorList.class.php');
+lmb_require('limb/validation/src/lmbErrorList.class.php');
 lmb_require('limb/validation/src/lmbValidator.class.php');
 
 class lmbController extends lmbAbstractController
@@ -33,7 +33,7 @@
     $this->response = $this->toolkit->getResponse();
     $this->session = $this->toolkit->getSession();
     $this->view = $this->toolkit->getView();
-    $this->error_list = new lmbWebAppErrorList();
+    $this->error_list = new lmbErrorList();
     $this->validator = new lmbValidator($this->error_list);
   }
 

Modified: 3.x/trunk/limb/web_app/src/fetcher/lmbFlashBoxErrorsFetcher.class.php
===================================================================
--- 3.x/trunk/limb/web_app/src/fetcher/lmbFlashBoxErrorsFetcher.class.php	2007-04-05 09:55:30 UTC (rev 5531)
+++ 3.x/trunk/limb/web_app/src/fetcher/lmbFlashBoxErrorsFetcher.class.php	2007-04-05 10:31:47 UTC (rev 5532)
@@ -20,7 +20,9 @@
 
     $flash_box = lmbToolkit :: instance()->getFlashBox();
     foreach($flash_box->getErrors() as $error)
-      $result[] = array('text' => $error);
+      $result[] = array('message' => $error,
+                        'text' => $error // for BC
+                        );
 
     $flash_box->resetErrors();
 

Modified: 3.x/trunk/limb/web_app/src/fetcher/lmbFlashBoxFetcher.class.php
===================================================================
--- 3.x/trunk/limb/web_app/src/fetcher/lmbFlashBoxFetcher.class.php	2007-04-05 09:55:30 UTC (rev 5531)
+++ 3.x/trunk/limb/web_app/src/fetcher/lmbFlashBoxFetcher.class.php	2007-04-05 10:31:47 UTC (rev 5532)
@@ -20,11 +20,15 @@
     $flash_box = lmbToolkit :: instance()->getFlashBox();
 
     foreach($flash_box->getErrors() as $error)
-      $result[] = array('text' => $error, 'is_error' => true, 'is_message' => false);
+      $result[] = array('message' => $error, 'is_error' => true, 'is_message' => false,
+                        'text' => $error // for BC
+                        );
 
 
     foreach($flash_box->getMessages() as $message)
-      $result[] = array('text' => $message, 'is_message' => true, 'is_error' => false);
+      $result[] = array('message' => $message, 'is_message' => true, 'is_error' => false,
+                        'text' => $message // for BC
+                        );
 
     $flash_box->reset();
 

Modified: 3.x/trunk/limb/web_app/src/fetcher/lmbFlashBoxMessagesFetcher.class.php
===================================================================
--- 3.x/trunk/limb/web_app/src/fetcher/lmbFlashBoxMessagesFetcher.class.php	2007-04-05 09:55:30 UTC (rev 5531)
+++ 3.x/trunk/limb/web_app/src/fetcher/lmbFlashBoxMessagesFetcher.class.php	2007-04-05 10:31:47 UTC (rev 5532)
@@ -20,7 +20,9 @@
 
     $flash_box = lmbToolkit :: instance()->getFlashBox();
     foreach($flash_box->getMessages() as $message)
-      $result[] = array('text' => $message);
+      $result[] = array('message' => $message,
+                        'text' => $message // for BC
+                        );
 
     $flash_box->resetMessages();
 

Deleted: 3.x/trunk/limb/web_app/src/fetcher/lmbMessageBoxErrorsFetcher.class.php
===================================================================
--- 3.x/trunk/limb/web_app/src/fetcher/lmbMessageBoxErrorsFetcher.class.php	2007-04-05 09:55:30 UTC (rev 5531)
+++ 3.x/trunk/limb/web_app/src/fetcher/lmbMessageBoxErrorsFetcher.class.php	2007-04-05 10:31:47 UTC (rev 5532)
@@ -1,31 +0,0 @@
-<?php
-/**
- * Limb Web Application Framework
- *
- * @link http://limb-project.com
- *
- * @copyright  Copyright &copy; 2004-2007 BIT
- * @license    LGPL http://www.gnu.org/copyleft/lesser.html
- * @version    $Id$
- * @package    web_app
- */
-lmb_require('limb/web_app/src/fetcher/lmbFetcher.class.php');
-
-class lmbMessageBoxErrorsFetcher extends lmbFetcher
-{
-  protected function _createDataSet()
-  {
-    $result = array();
-
-    foreach(lmbToolkit :: instance()->getMessageBox()->getErrors() as $error)
-    {
-      if(!is_object($error))
-        $result[] = new lmbDataspace(array('error' => $error));
-      else
-        $result[] = $error;
-    }
-
-    return new lmbArrayDataset($result);
-  }
-}
-?>

Deleted: 3.x/trunk/limb/web_app/src/fetcher/lmbMessageBoxMessagesFetcher.class.php
===================================================================
--- 3.x/trunk/limb/web_app/src/fetcher/lmbMessageBoxMessagesFetcher.class.php	2007-04-05 09:55:30 UTC (rev 5531)
+++ 3.x/trunk/limb/web_app/src/fetcher/lmbMessageBoxMessagesFetcher.class.php	2007-04-05 10:31:47 UTC (rev 5532)
@@ -1,26 +0,0 @@
-<?php
-/**
- * Limb Web Application Framework
- *
- * @link http://limb-project.com
- *
- * @copyright  Copyright &copy; 2004-2007 BIT
- * @license    LGPL http://www.gnu.org/copyleft/lesser.html
- * @version    $Id$
- * @package    web_app
- */
-lmb_require('limb/web_app/src/fetcher/lmbFetcher.class.php');
-
-class lmbMessageBoxMessagesFetcher extends lmbFetcher
-{
-  protected function _createDataSet()
-  {
-    $result = array();
-
-    foreach(lmbToolkit :: instance()->getMessageBox()->getMessages() as $message)
-      $result[] = array('message' => $message);
-
-    return new lmbArrayDataset($result);
-  }
-}
-?>

Deleted: 3.x/trunk/limb/web_app/src/template/tags/fetch/message_box.tag.php
===================================================================
--- 3.x/trunk/limb/web_app/src/template/tags/fetch/message_box.tag.php	2007-04-05 09:55:30 UTC (rev 5531)
+++ 3.x/trunk/limb/web_app/src/template/tags/fetch/message_box.tag.php	2007-04-05 10:31:47 UTC (rev 5532)
@@ -1,34 +0,0 @@
-<?php
-/**
- * Limb Web Application Framework
- *
- * @link http://limb-project.com
- *
- * @copyright  Copyright &copy; 2004-2007 BIT
- * @license    LGPL http://www.gnu.org/copyleft/lesser.html
- * @version    $Id: active_record_fetch.tag.php 5421 2007-03-29 12:49:10Z serega $
- * @package    web_app
- */
-require_once('limb/wact/src/tags/fetch/fetch.tag.php');
-
-/**
-* @tag message_box, messagebox
-*/
-class lmbMessageBoxTag extends WactFetchTag
-{
-  function preParse()
-  {
-    if($this->getBoolAttribute('errors'))
-      $this->setAttribute('using', 'limb/web_app/src/fetcher/lmbMessageBoxErrorsFetcher');
-    elseif($this->getBoolAttribute('messages'))
-      $this->setAttribute('using', 'limb/web_app/src/fetcher/lmbMessageBoxMessagesFetcher');
-    else
-      $this->setAttribute('using', 'limb/web_app/src/fetcher/lmbMessageBoxFetcher');
-
-
-    return parent :: preParse();
-  }
-
-}
-
-?>
\ No newline at end of file

Modified: 3.x/trunk/limb/web_app/src/toolkit/lmbWebAppTools.class.php
===================================================================
--- 3.x/trunk/limb/web_app/src/toolkit/lmbWebAppTools.class.php	2007-04-05 09:55:30 UTC (rev 5531)
+++ 3.x/trunk/limb/web_app/src/toolkit/lmbWebAppTools.class.php	2007-04-05 10:31:47 UTC (rev 5532)
@@ -19,7 +19,6 @@
   protected $view;
   protected $dispatched_controller;
   protected $routes;
-  protected $message_box;
   protected $flash_box;
 
   function getSession()
@@ -99,17 +98,6 @@
     $this->routes = $routes;
   }
 
-  function getMessageBox()
-  {
-    if(!is_object($this->message_box))
-    {
-      lmb_require('limb/web_app/src/util/lmbMessageBox.class.php');
-      $this->message_box = new lmbMessageBox();
-    }
-
-    return $this->message_box;
-  }
-
   function getFlashBox()
   {
     if(!is_object($this->flash_box))

Deleted: 3.x/trunk/limb/web_app/src/validation/lmbWebAppErrorList.class.php
===================================================================
--- 3.x/trunk/limb/web_app/src/validation/lmbWebAppErrorList.class.php	2007-04-05 09:55:30 UTC (rev 5531)
+++ 3.x/trunk/limb/web_app/src/validation/lmbWebAppErrorList.class.php	2007-04-05 10:31:47 UTC (rev 5532)
@@ -1,22 +0,0 @@
-<?php
-/**
- * Limb Web Application Framework
- *
- * @link http://limb-project.com
- *
- * @copyright  Copyright &copy; 2004-2007 BIT
- * @license    LGPL http://www.gnu.org/copyleft/lesser.html
- * @version    $Id$
- * @package    web_app
- */
-lmb_require('limb/validation/src/lmbErrorList.class.php');
-
-class lmbWebAppErrorList extends lmbErrorList
-{
-  function addError($message, $fields = array(), $values = array())
-  {
-    $error = parent :: addError($message, $fields, $values);
-
-    lmbToolkit :: instance()->getMessageBox()->addError($error);
-  }
-}

Deleted: 3.x/trunk/limb/web_app/tests/cases/db/validation/lmbWebAppErrorListTest.class.php
===================================================================
--- 3.x/trunk/limb/web_app/tests/cases/db/validation/lmbWebAppErrorListTest.class.php	2007-04-05 09:55:30 UTC (rev 5531)
+++ 3.x/trunk/limb/web_app/tests/cases/db/validation/lmbWebAppErrorListTest.class.php	2007-04-05 10:31:47 UTC (rev 5532)
@@ -1,49 +0,0 @@
-<?php
-/**
- * Limb Web Application Framework
- *
- * @link http://limb-project.com
- *
- * @copyright  Copyright &copy; 2004-2007 BIT
- * @license    LGPL http://www.gnu.org/copyleft/lesser.html
- * @version    $Id$
- * @package    web_app
- */
-lmb_require('limb/web_app/src/validation/lmbWebAppErrorList.class.php');
-
-class lmbWebAppErrorListTest extends UnitTestCase
-{
-  var $message_box;
-
-  function setUp()
-  {
-    $this->message_box = lmbToolkit :: save()->getMessageBox();
-  }
-
-  function tearDown()
-  {
-    lmbToolkit :: restore();
-  }
-
-  function testAddError()
-  {
-    $list = new lmbWebAppErrorList();
-
-    $this->assertTrue($list->isValid());
-
-    $list->addError($message = 'error_group', array('foo'), array('FOO'));
-
-    $this->assertFalse($list->isValid());
-
-    $this->assertEqual($list->count(), 1);
-
-    $errors = $list->export();
-    $this->assertEqual(sizeof($errors), 1);
-    $this->assertEqual($errors[0]->getMessage(), $message);
-    $this->assertEqual($errors[0]->getFields(), array('foo'));
-    $this->assertEqual($errors[0]->getValues(), array('FOO'));
-
-    $this->assertTrue($this->message_box->hasErrors());
-  }
-}
-?>
\ No newline at end of file

Modified: 3.x/trunk/limb/web_app/tests/cases/plain/fetcher/lmbFlashBoxErrorsFetcherTest.class.php
===================================================================
--- 3.x/trunk/limb/web_app/tests/cases/plain/fetcher/lmbFlashBoxErrorsFetcherTest.class.php	2007-04-05 09:55:30 UTC (rev 5531)
+++ 3.x/trunk/limb/web_app/tests/cases/plain/fetcher/lmbFlashBoxErrorsFetcherTest.class.php	2007-04-05 10:31:47 UTC (rev 5532)
@@ -40,9 +40,9 @@
     $rs = $fetcher->fetch();
 
     $rs->rewind();
-    $this->assertEqual($rs->current()->get('text'), 'Error1');
+    $this->assertEqual($rs->current()->get('message'), 'Error1');
     $rs->next();
-    $this->assertEqual($rs->current()->get('text'), 'Error2');
+    $this->assertEqual($rs->current()->get('message'), 'Error2');
   }
 
   function testFetcherResetsErrorsList()

Modified: 3.x/trunk/limb/web_app/tests/cases/plain/fetcher/lmbFlashBoxFetcherTest.class.php
===================================================================
--- 3.x/trunk/limb/web_app/tests/cases/plain/fetcher/lmbFlashBoxFetcherTest.class.php	2007-04-05 09:55:30 UTC (rev 5531)
+++ 3.x/trunk/limb/web_app/tests/cases/plain/fetcher/lmbFlashBoxFetcherTest.class.php	2007-04-05 10:31:47 UTC (rev 5532)
@@ -42,12 +42,12 @@
     $rs->rewind();
     $this->assertFalse($rs->current()->get('is_message'));
     $this->assertTrue($rs->current()->get('is_error'));
-    $this->assertEqual($rs->current()->get('text'), 'Error2');
+    $this->assertEqual($rs->current()->get('message'), 'Error2');
 
     $rs->next();
     $this->assertTrue($rs->current()->get('is_message'));
     $this->assertFalse($rs->current()->get('is_error'));
-    $this->assertEqual($rs->current()->get('text'), 'Message1');
+    $this->assertEqual($rs->current()->get('message'), 'Message1');
 
   }
 

Modified: 3.x/trunk/limb/web_app/tests/cases/plain/fetcher/lmbFlashBoxMessagesFetcherTest.class.php
===================================================================
--- 3.x/trunk/limb/web_app/tests/cases/plain/fetcher/lmbFlashBoxMessagesFetcherTest.class.php	2007-04-05 09:55:30 UTC (rev 5531)
+++ 3.x/trunk/limb/web_app/tests/cases/plain/fetcher/lmbFlashBoxMessagesFetcherTest.class.php	2007-04-05 10:31:47 UTC (rev 5532)
@@ -40,9 +40,9 @@
     $rs = $fetcher->fetch();
 
     $rs->rewind();
-    $this->assertEqual($rs->current()->get('text'), 'Message1');
+    $this->assertEqual($rs->current()->get('message'), 'Message1');
     $rs->next();
-    $this->assertEqual($rs->current()->get('text'), 'Message2');
+    $this->assertEqual($rs->current()->get('message'), 'Message2');
   }
 
   function testFetcherResetsMessagesList()

Deleted: 3.x/trunk/limb/web_app/tests/cases/plain/fetcher/lmbMessageBoxErrorsFetcherTest.class.php
===================================================================
--- 3.x/trunk/limb/web_app/tests/cases/plain/fetcher/lmbMessageBoxErrorsFetcherTest.class.php	2007-04-05 09:55:30 UTC (rev 5531)
+++ 3.x/trunk/limb/web_app/tests/cases/plain/fetcher/lmbMessageBoxErrorsFetcherTest.class.php	2007-04-05 10:31:47 UTC (rev 5532)
@@ -1,43 +0,0 @@
-<?php
-/**
- * Limb Web Application Framework
- *
- * @link http://limb-project.com
- *
- * @copyright  Copyright &copy; 2004-2007 BIT
- * @license    LGPL http://www.gnu.org/copyleft/lesser.html
- * @version    $Id$
- * @package    web_app
- */
-lmb_require('limb/web_app/src/fetcher/lmbMessageBoxErrorsFetcher.class.php');
-
-class lmbMessageBoxErrorsFetcherTest extends UnitTestCase
-{
-  protected $toolkit;
-
-  function setUp()
-  {
-    $this->toolkit = lmbToolkit :: save();
-  }
-
-  function tearDown()
-  {
-    lmbToolkit :: restore();
-  }
-
-  function testFetch()
-  {
-    $this->toolkit->getMessageBox()->addError('Error1');
-    $this->toolkit->getMessageBox()->addError('Error2');
-
-    $fetcher = new lmbMessageBoxErrorsFetcher();
-    $rs = $fetcher->fetch();
-
-    $rs->rewind();
-    $this->assertEqual($rs->current()->get('error'), 'Error1');
-    $rs->next();
-    $this->assertEqual($rs->current()->get('error'), 'Error2');
-  }
-
-}
-?>

Deleted: 3.x/trunk/limb/web_app/tests/cases/plain/fetcher/lmbMessageBoxMessagesFetcherTest.class.php
===================================================================
--- 3.x/trunk/limb/web_app/tests/cases/plain/fetcher/lmbMessageBoxMessagesFetcherTest.class.php	2007-04-05 09:55:30 UTC (rev 5531)
+++ 3.x/trunk/limb/web_app/tests/cases/plain/fetcher/lmbMessageBoxMessagesFetcherTest.class.php	2007-04-05 10:31:47 UTC (rev 5532)
@@ -1,43 +0,0 @@
-<?php
-/**
- * Limb Web Application Framework
- *
- * @link http://limb-project.com
- *
- * @copyright  Copyright &copy; 2004-2007 BIT
- * @license    LGPL http://www.gnu.org/copyleft/lesser.html
- * @version    $Id$
- * @package    web_app
- */
-lmb_require('limb/web_app/src/fetcher/lmbMessageBoxMessagesFetcher.class.php');
-
-class lmbMessageBoxMessagesFetcherTest extends UnitTestCase
-{
-  protected $toolkit;
-
-  function setUp()
-  {
-    $this->toolkit = lmbToolkit :: save();
-  }
-
-  function tearDown()
-  {
-    lmbToolkit :: restore();
-  }
-
-  function testFetch()
-  {
-    $this->toolkit->getMessageBox()->addMessage('Message1');
-    $this->toolkit->getMessageBox()->addMessage('Message2');
-
-    $fetcher = new lmbMessageBoxMessagesFetcher();
-    $rs = $fetcher->fetch();
-
-    $rs->rewind();
-    $this->assertEqual($rs->current()->get('message'), 'Message1');
-    $rs->next();
-    $this->assertEqual($rs->current()->get('message'), 'Message2');
-  }
-
-}
-?>

Modified: 3.x/trunk/limb/web_app/tests/cases/plain/template/tags/fetch/lmbFlashBoxTagTest.class.php
===================================================================
--- 3.x/trunk/limb/web_app/tests/cases/plain/template/tags/fetch/lmbFlashBoxTagTest.class.php	2007-04-05 09:55:30 UTC (rev 5531)
+++ 3.x/trunk/limb/web_app/tests/cases/plain/template/tags/fetch/lmbFlashBoxTagTest.class.php	2007-04-05 10:31:47 UTC (rev 5532)
@@ -22,7 +22,7 @@
   {
     $template = '<flash_box target="flash_box"/>'.
                  '<list:list id="flash_box"><list:ITEM>'.
-                 '{$text}|'.
+                 '{$message}|'.
                  '</list:ITEM></list:list>';
 
     $this->toolkit->flashError('Error1');
@@ -39,7 +39,7 @@
   {
     $template = '<flash_box target="flash_box" errors="true"/>'.
                  '<list:list id="flash_box"><list:ITEM>'.
-                 '{$text}|'.
+                 '{$message}|'.
                  '</list:ITEM></list:list>';
 
     $this->toolkit->flashError('Error1');
@@ -58,7 +58,7 @@
   {
     $template = '<flash_box target="flash_box" messages="true"/>'.
                  '<list:list id="flash_box"><list:ITEM>'.
-                 '{$text}|'.
+                 '{$message}|'.
                  '</list:ITEM></list:list>';
 
     $this->toolkit->flashError('Error1');

Deleted: 3.x/trunk/limb/web_app/tests/cases/plain/template/tags/fetch/lmbMessageBoxTagTest.class.php
===================================================================
--- 3.x/trunk/limb/web_app/tests/cases/plain/template/tags/fetch/lmbMessageBoxTagTest.class.php	2007-04-05 09:55:30 UTC (rev 5531)
+++ 3.x/trunk/limb/web_app/tests/cases/plain/template/tags/fetch/lmbMessageBoxTagTest.class.php	2007-04-05 10:31:47 UTC (rev 5532)
@@ -1,32 +0,0 @@
-<?php
-/**
- * Limb Web Application Framework
- *
- * @link http://limb-project.com
- *
- * @copyright  Copyright &copy; 2004-2007 BIT
- * @license    LGPL http://www.gnu.org/copyleft/lesser.html
- * @version    $Id: lmbRouteUrlTagTest.class.php 5287 2007-03-20 08:39:30Z serega $
- * @package    web_app
- */
-
-class lmbMessageBoxTagTest extends lmbWactTestCase
-{
-  function _testPassFlashBoxMessagesToListByTargetAttribute()
-  {
-    $template = '<message_box target="flash_box"/>'.
-                 '<list:list id="flash_box"><list:ITEM >'.
-                 '{$text}|'.
-                 '</list:ITEM></list:list>';
-
-    $this->toolkit->flashError('Error1');
-    $this->toolkit->flashError('Error2');
-
-    $this->registerTestingTemplate('/limb/flash_box/with_target.html', $template);
-
-    $page = $this->initTemplate('/limb/flash_box/with_target.html');
-
-    $this->assertEqual($page->capture(), 'Error1|Error2|');
-  }
-}
-?>



More information about the limb-svn mailing list