function testLoadIntoDataObject()
 {
     $obj = new MoneyTest_DataObject();
     $this->assertType('Money', $obj->obj('MyMoney'));
     $m = new Money();
     $m->setValue(array('Currency' => 'EUR', 'Amount' => 1.23));
     $obj->MyMoney = $m;
     $this->assertEquals($obj->MyMoney->getCurrency(), 'EUR');
     $this->assertEquals($obj->MyMoney->getAmount(), 1.23);
 }
 public function testLoadIntoDataObject()
 {
     $obj = new MoneyTest_DataObject();
     $this->assertInstanceOf('SilverStripe\\ORM\\FieldType\\DBMoney', $obj->obj('MyMoney'));
     $m = new DBMoney();
     $m->setValue(array('Currency' => 'EUR', 'Amount' => 1.23));
     $obj->MyMoney = $m;
     $this->assertEquals($obj->MyMoney->getCurrency(), 'EUR');
     $this->assertEquals($obj->MyMoney->getAmount(), 1.23);
 }