diff options
author | msquare <msquare@notrademark.de> | 2016-10-09 09:40:11 +0200 |
---|---|---|
committer | msquare <msquare@notrademark.de> | 2016-10-09 09:40:11 +0200 |
commit | d59b1c8812f62848acc2bf19f020abf4949e75ef (patch) | |
tree | 1db433f283ce1fa8a16e08ffd4a58b69fb46889a /test/model/RoomModelTest.php | |
parent | 1d4811cca51a00de27328d5608dbc23e46854297 (diff) |
fix phpunit config
Diffstat (limited to 'test/model/RoomModelTest.php')
-rw-r--r-- | test/model/RoomModelTest.php | 33 |
1 files changed, 33 insertions, 0 deletions
diff --git a/test/model/RoomModelTest.php b/test/model/RoomModelTest.php new file mode 100644 index 00000000..33e6ca37 --- /dev/null +++ b/test/model/RoomModelTest.php @@ -0,0 +1,33 @@ +<?php + +class RoomModelTest extends PHPUnit_Framework_TestCase { + + private $room_id = null; + + public function create_Room() { + $this->room_id = Room_create('test', false, true, ''); + } + + public function test_Room() { + $this->create_Room(); + + $room = Room($this->room_id); + + $this->assertNotFalse($room); + $this->assertNotNull($room); + $this->assertEquals($room['Name'], 'test'); + + $this->assertNull(Room(- 1)); + } + + /** + * @after + */ + public function teardown() { + if ($this->room_id != null) { + Room_delete($this->room_id); + } + } +} + +?> |