summaryrefslogtreecommitdiff
path: root/tests/app
diff options
context:
space:
mode:
authorGreg Roach <fisharebest@webtrees.net>2019-02-01 11:35:46 +0000
committerGreg Roach <fisharebest@webtrees.net>2019-02-01 11:35:46 +0000
commit94c9bb3d58b116d5008dfb3b40fd5da0683a68c6 (patch)
tree66b2b32939e3796b525791b49842f2439370ece4 /tests/app
parent3d0d3c4eac0d9885ecf85cce0ac6e76860c614d4 (diff)
downloadwebtrees-94c9bb3d58b116d5008dfb3b40fd5da0683a68c6.tar.gz
webtrees-94c9bb3d58b116d5008dfb3b40fd5da0683a68c6.tar.bz2
webtrees-94c9bb3d58b116d5008dfb3b40fd5da0683a68c6.zip
Refactor admin controller
Diffstat (limited to 'tests/app')
-rw-r--r--tests/app/Http/Controllers/Admin/ChangesLogControllerTest.php63
1 files changed, 63 insertions, 0 deletions
diff --git a/tests/app/Http/Controllers/Admin/ChangesLogControllerTest.php b/tests/app/Http/Controllers/Admin/ChangesLogControllerTest.php
new file mode 100644
index 0000000000..180d7699e4
--- /dev/null
+++ b/tests/app/Http/Controllers/Admin/ChangesLogControllerTest.php
@@ -0,0 +1,63 @@
+<?php
+/**
+ * webtrees: online genealogy
+ * Copyright (C) 2019 webtrees development team
+ * This program is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 3 of the License, or
+ * (at your option) any later version.
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ * You should have received a copy of the GNU General Public License
+ * along with this program. If not, see <http://www.gnu.org/licenses/>.
+ */
+declare(strict_types=1);
+
+namespace Fisharebest\Webtrees\Http\Controllers\Admin;
+
+use Symfony\Component\HttpFoundation\Response;
+
+/**
+ * Test the changes log controller
+ *
+ * @covers \Fisharebest\Webtrees\Http\Controllers\Admin\ChangesLogController
+ */
+class ChangesLogControllerTest extends \Fisharebest\Webtrees\TestCase
+{
+ protected static $uses_database = true;
+
+ /**
+ * @return void
+ */
+ public function testChangeLog(): void
+ {
+ $controller = app()->make(ChangesLogController::class);
+ $response = app()->dispatch($controller, 'changesLog');
+
+ $this->assertInstanceOf(Response::class, $response);
+ }
+
+ /**
+ * @return void
+ */
+ public function testChangeLogData(): void
+ {
+ $controller = app()->make(ChangesLogController::class);
+ $response = app()->dispatch($controller, 'changesLogData');
+
+ $this->assertInstanceOf(Response::class, $response);
+ }
+
+ /**
+ * @return void
+ */
+ public function testChangeLogDownload(): void
+ {
+ $controller = app()->make(ChangesLogController::class);
+ $response = app()->dispatch($controller, 'changesLogDownload');
+
+ $this->assertInstanceOf(Response::class, $response);
+ }
+}