Skip to content

Commit 8f41065

Browse files
committed
Fix export of test_app folder
1 parent a75e3a4 commit 8f41065

File tree

9 files changed

+27
-20
lines changed

9 files changed

+27
-20
lines changed

.gitattributes

+8
Original file line numberDiff line numberDiff line change
@@ -33,3 +33,11 @@
3333
*.ico binary
3434
*.mo binary
3535
*.pdf binary
36+
37+
# Remove files for archives generated using `git archive`
38+
phpunit.xml.dist export-ignore
39+
.travis.yml export-ignore
40+
.gitignore export-ignore
41+
.gitattributes export-ignore
42+
.editorconfig export-ignore
43+
tests/test_app export-ignore

composer.json

+5-5
Original file line numberDiff line numberDiff line change
@@ -36,15 +36,15 @@
3636
},
3737
"autoload": {
3838
"psr-4": {
39-
"Queue\\": "src",
40-
"Queue\\Test\\Fixture\\": "tests/Fixture"
39+
"Queue\\": "src/",
40+
"Queue\\Test\\Fixture\\": "tests/Fixture/"
4141
}
4242
},
4343
"autoload-dev": {
4444
"psr-4": {
45-
"Queue\\Test\\": "tests",
46-
"TestApp\\": "tests/test_app/src",
47-
"Cake\\Test\\": "vendor/cakephp/cakephp/tests"
45+
"Queue\\Test\\": "tests/",
46+
"App\\": "tests/test_app/src/",
47+
"Cake\\Test\\": "vendor/cakephp/cakephp/tests/"
4848
}
4949
},
5050
"scripts": {

src/Controller/Admin/QueueController.php

+2-2
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ class QueueController extends AppController {
2323
* QueueController::beforeFilter()
2424
*
2525
* @param \Cake\Event\Event $event
26-
* @return void
26+
* @return \Cake\Http\Response|null
2727
*/
2828
public function beforeFilter(Event $event) {
2929
$this->QueuedJobs->initConfig();
@@ -35,7 +35,7 @@ public function beforeFilter(Event $event) {
3535
* Admin center.
3636
* Manage queues from admin backend (without the need to open ssh console window).
3737
*
38-
* @return void
38+
* @return \Cake\Http\Response|null
3939
*/
4040
public function index() {
4141
$status = $this->_status();

src/Template/Admin/Queue/index.ctp

+6-6
Original file line numberDiff line numberDiff line change
@@ -5,9 +5,9 @@
55
use Cake\Core\Configure;
66
?>
77
<div class="page index col-xs-12">
8-
<h2><?php echo __d('queue', 'Queue');?></h2>
8+
<h1><?php echo __d('queue', 'Queue');?></h1>
99

10-
<h3><?php echo __d('queue', 'Status'); ?></h3>
10+
<h2><?php echo __d('queue', 'Status'); ?></h2>
1111
<?php if ($status) { ?>
1212
<?php
1313
$running = (time() - $status['time']) < MINUTE;
@@ -21,7 +21,7 @@ use Cake\Core\Configure;
2121
n/a
2222
<?php } ?>
2323

24-
<h3><?php echo __d('queue', 'Queued Jobs'); ?></h3>
24+
<h2><?php echo __d('queue', 'Queued Jobs'); ?></h2>
2525
<?php
2626
echo $current;
2727
?> task(s) await processing
@@ -50,7 +50,7 @@ foreach ($pendingDetails as $item) {
5050
?>
5151
</ol>
5252

53-
<h3><?php echo __d('queue', 'Statistics'); ?></h3>
53+
<h2><?php echo __d('queue', 'Statistics'); ?></h2>
5454
<ul>
5555
<?php
5656
foreach ($data as $item) {
@@ -69,7 +69,7 @@ if (empty($data)) {
6969
?>
7070
</ul>
7171

72-
<h3>Settings</h3>
72+
<h2>Settings</h2>
7373
<ul>
7474
<?php
7575
$configurations = Configure::read('Queue');
@@ -88,7 +88,7 @@ if (empty($data)) {
8888
?>
8989
</ul>
9090

91-
<h3>Trigger Test/Demo Jobs</h3>
91+
<h2>Trigger Test/Demo Jobs</h2>
9292
<ul>
9393
<?php
9494
foreach ($tasks as $task) {

src/Template/Admin/Queue/processes.ctp

+2-2
Original file line numberDiff line numberDiff line change
@@ -7,9 +7,9 @@ use Cake\I18n\Time;
77

88
?>
99
<div class="page index col-xs-12">
10-
<h2><?php echo __d('queue', 'Queue');?></h2>
10+
<h1><?php echo __d('queue', 'Queue');?></h1>
1111

12-
<h3><?php echo __d('queue', 'Current Queue Processes'); ?></h3>
12+
<h2><?php echo __d('queue', 'Current Queue Processes'); ?></h2>
1313
<ul>
1414
<?php
1515
foreach ($processes as $process => $timestamp) {

tests/bootstrap.php

+1-2
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@
3333
require CORE_PATH . 'config/bootstrap.php';
3434

3535
Cake\Core\Configure::write('App', [
36-
'namespace' => 'TestApp',
36+
'namespace' => 'App',
3737
'encoding' => 'UTF-8',
3838
'paths' => [
3939
'templates' => [ROOT . DS . 'tests' . DS . 'test_app' . DS . 'src' . DS . 'Template' . DS],
@@ -89,7 +89,6 @@
8989

9090
DispatcherFactory::add('Routing');
9191
DispatcherFactory::add('ControllerFactory');
92-
class_alias(AppController::class, 'App\Controller\AppController');
9392

9493
Cake\Mailer\Email::configTransport('default', [
9594
'className' => 'Debug',

tests/test_app/src/Controller/AppController.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
<?php
2-
namespace TestApp\Controller;
2+
namespace App\Controller;
33

44
use Cake\Controller\Controller;
55

tests/test_app/src/Model/Table/QueuedJobsTable.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
<?php
22

3-
namespace TestApp\Model\Table;
3+
namespace App\Model\Table;
44

55
use Queue\Model\Table\QueuedJobsTable as BaseQueuedJobsTable;
66

tests/test_app/src/Shell/TestQueueShell.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
<?php
2-
namespace TestApp\Shell;
2+
namespace App\Shell;
33

44
use Cake\Console\Shell;
55
use Queue\Shell\QueueShell;

0 commit comments

Comments
 (0)