public function testSetFieldValue() { $value1 = $this->createFieldObject('field1', 'oldfieldvalue'); $value2 = $this->createFieldObject('field2', true); $fields = array('field1' => $value1, 'field2' => $value2); $information = new MetaInformation(); $information->setFields($fields); $expectedValue = 'newFieldValue'; $information->setFieldValue('field2', $expectedValue); $this->assertEquals($expectedValue, $information->getField('field2')->value, 'field2 should have new value'); }