diff --git a/composer.json b/composer.json index c1cf81d..3f2d349 100644 --- a/composer.json +++ b/composer.json @@ -5,6 +5,9 @@ "require": { "fabpot/goutte": "^3.1" }, + "require-dev": { + "phpunit/phpunit": "^5.7" + }, "authors": [ { "name": "Shikiryu", diff --git a/phpunit.xml b/phpunit.xml new file mode 100644 index 0000000..6f34db7 --- /dev/null +++ b/phpunit.xml @@ -0,0 +1,7 @@ + + + + tests + + + diff --git a/tests/AccountTest.php b/tests/AccountTest.php new file mode 100644 index 0000000..036a47b --- /dev/null +++ b/tests/AccountTest.php @@ -0,0 +1,33 @@ + 'text@example.com', + 'password' => 'password', + ]); + $this->account = new Account($config); + } + + protected function tearDown() + { + $this->account = null; + } + + public function testAdd() + { + $result = $this->account->getConfig(); + $this->assertInstanceOf( \Shikiryu\LBCReposter\Config::class, $result ); + } + +}