| 1 |
<?php |
| 2 |
|
| 3 |
namespace Vimeography_Unit_Tests; |
| 4 |
|
| 5 |
class Tests_Core extends Vimeography_UnitTestCase { |
| 6 |
|
| 7 |
protected $_class; |
| 8 |
protected $_gallery_atts; |
| 9 |
|
| 10 |
/** |
| 11 |
* Runs before every test. |
| 12 |
* Think of it as emulating what would usually happen once the plugin is activated on a Wordpress site. |
| 13 |
*/ |
| 14 |
public function setUp() |
| 15 |
{ |
| 16 |
parent::setUp(); |
| 17 |
require_once VIMEOGRAPHY_PATH . 'lib/core.php'; |
| 18 |
require_once VIMEOGRAPHY_PATH . 'lib/core/basic.php'; |
| 19 |
|
| 20 |
$this->_gallery_atts = array( |
| 21 |
'theme' => 'bugsauce', |
| 22 |
'featured' => '', |
| 23 |
'source' => '/channels/staffpicks/videos', |
| 24 |
'limit' => 25, |
| 25 |
'cache' => 3600, |
| 26 |
'width' => '', |
| 27 |
); |
| 28 |
|
| 29 |
$this->_class = new \Vimeography_Core_Basic($this->_gallery_atts); |
| 30 |
} |
| 31 |
|
| 32 |
public function test_vimeography_admin_plugins_instance() { |
| 33 |
$this->assertClassHasAttribute( '_vimeo', 'Vimeography_Core_Basic' ); |
| 34 |
} |
| 35 |
|
| 36 |
/** |
| 37 |
* @covers Vimeography_Core::_endpoint |
| 38 |
*/ |
| 39 |
// public function test_vimeography_endpoint() { |
| 40 |
// $this->assertEquals('/channels/staffpicks/videos', $this->_class->_endpoint); |
| 41 |
// } |
| 42 |
|
| 43 |
public function tearDown() { } |
| 44 |
|
| 45 |
} |
| 46 |
|