Cachet/tests/Api/ComponentTest.php

39 lines
882 B
PHP
Raw Normal View History

2015-06-01 21:32:02 +01:00
<?php
/*
* This file is part of Cachet.
*
* (c) Cachet HQ <support@cachethq.io>
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
namespace CachetHQ\Tests\Cachet\Api;
use CachetHQ\Tests\Cachet\AbstractTestCase;
use Illuminate\Foundation\Testing\DatabaseMigrations;
class ComponentTest extends AbstractTestCase
{
use DatabaseMigrations;
public function testGetComponents()
{
$this->get('/api/v1/components')->seeJson(['data' => []]);
}
2015-06-01 22:03:23 +01:00
/**
* @expectedException \Illuminate\Database\Eloquent\ModelNotFoundException
*/
2015-06-01 21:32:02 +01:00
public function testGetInvalidComponent()
{
$this->get('/api/v1/components/1');
}
/*public function testPostComponentUnauthorized()
{
$this->post('/api/v1/components')->seeJson(['data']);
}*/
}