Permalink
Browse files

MINOR: Removed notice-level errors from form field construction.

  • Loading branch information...
1 parent 7c6050b commit 6a08a82c9c83611db5a9e6e361d02fec1d3cb302 @sminnee sminnee committed Jan 10, 2012
Showing with 3 additions and 4 deletions.
  1. +1 −1 forms/DateField.php
  2. +0 −1 forms/FormField.php
  3. +2 −2 tests/forms/TextareaFieldTest.php
View
2 forms/DateField.php
@@ -107,7 +107,7 @@ function __construct($name, $title = null, $value = null) {
}
}
- parent::__construct($name, $title, $value, $form, $rightTitle);
+ parent::__construct($name, $title, $value);
}
function FieldHolder() {
View
1 forms/FormField.php
@@ -106,7 +106,6 @@ function __construct($name, $title = null, $value = null) {
$this->title = ($title === null) ? $name : $title;
if($value !== NULL) $this->setValue($value);
- if($form) $this->setForm($form);
parent::__construct();
}
View
4 tests/forms/TextareaFieldTest.php
@@ -7,7 +7,7 @@ class TextareaFieldTest extends SapphireTest {
*/
function testTextEncoding() {
$inputText = "This is my <text>These are some unicodes: äöü&<>";
- $field = new TextareaField("Test", "Test", 5, 20);
+ $field = new TextareaField("Test", "Test");
$field->setValue($inputText);
$this->assertContains('This is my &lt;text&gt;These are some unicodes: &auml;&ouml;&uuml;&amp;&lt;&gt;', $field->Field());
}
@@ -17,7 +17,7 @@ function testTextEncoding() {
*/
function testReadonlyTextEncoding() {
$inputText = "This is my <text>These are some unicodes: äöü&<>";
- $field = new TextareaField("Test", "Test", 5, 20);
+ $field = new TextareaField("Test", "Test");
$field = $field->performReadonlyTransformation();
$field->setValue($inputText);
$this->assertContains('This is my &lt;text&gt;These are some unicodes: &auml;&ouml;&uuml;&amp;&lt;&gt;', $field->Field());

0 comments on commit 6a08a82

Please sign in to comment.