-
Notifications
You must be signed in to change notification settings - Fork 115
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #195 from cakephp/tests-193
Include table with schema name in snapshot
- Loading branch information
Showing
13 changed files
with
206 additions
and
49 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
2 changes: 1 addition & 1 deletion
2
...in/Blog/src/Model/Table/ArticlesTable.php → ...estBlog/src/Model/Table/ArticlesTable.php
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,5 @@ | ||
<?php | ||
namespace Blog\Model\Table; | ||
namespace TestBlog\Model\Table; | ||
|
||
use Cake\ORM\Table; | ||
|
||
|
27 changes: 27 additions & 0 deletions
27
tests/test_app/Plugin/TestBlog/src/Model/Table/CategoriesTable.php
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,27 @@ | ||
<?php | ||
namespace TestBlog\Model\Table; | ||
|
||
use Cake\ORM\Table; | ||
|
||
/** | ||
* Articles Model | ||
* | ||
*/ | ||
class CategoriesTable extends Table | ||
{ | ||
public function initialize(array $config) | ||
{ | ||
$db = getenv('DB'); | ||
switch($db) { | ||
case 'sqlite': | ||
$dbName = ':memory:.'; | ||
break; | ||
case 'mysql': | ||
case 'pgsql': | ||
$dbName = 'cakephp_test.'; | ||
break; | ||
} | ||
$dbName .= 'categories'; | ||
$this->table($dbName); | ||
} | ||
} |
2 changes: 1 addition & 1 deletion
2
...Plugin/Blog/src/Model/Table/DogsTable.php → ...in/TestBlog/src/Model/Table/DogsTable.php
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,5 @@ | ||
<?php | ||
namespace Blog\Model\Table; | ||
namespace TestBlog\Model\Table; | ||
|
||
use Cake\ORM\Table; | ||
|
||
|
16 changes: 16 additions & 0 deletions
16
tests/test_app/Plugin/TestBlog/src/Model/Table/SpecialTagsTable.php
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
<?php | ||
namespace TestBlog\Model\Table; | ||
|
||
use Cake\ORM\Table; | ||
|
||
/** | ||
* Articles Model | ||
* | ||
*/ | ||
class SpecialTagsTable extends Table | ||
{ | ||
public function initialize(array $config) | ||
{ | ||
$this->table('alternative.special_tags'); | ||
} | ||
} |