| 15403 |
manish.sha |
1 |
<?php
|
|
|
2 |
/**
|
|
|
3 |
* CategoryFixture
|
|
|
4 |
*
|
|
|
5 |
*/
|
|
|
6 |
class CategoryFixture extends CakeTestFixture {
|
|
|
7 |
|
|
|
8 |
/**
|
|
|
9 |
* Fields
|
|
|
10 |
*
|
|
|
11 |
* @var array
|
|
|
12 |
*/
|
|
|
13 |
public $fields = array(
|
|
|
14 |
'id' => array('type' => 'integer', 'null' => false, 'default' => null, 'length' => 10, 'unsigned' => true, 'key' => 'primary'),
|
|
|
15 |
'parent_id' => array('type' => 'integer', 'null' => true, 'default' => null, 'length' => 10, 'unsigned' => false),
|
|
|
16 |
'lft' => array('type' => 'integer', 'null' => true, 'default' => null, 'length' => 10, 'unsigned' => false),
|
|
|
17 |
'rght' => array('type' => 'integer', 'null' => true, 'default' => null, 'length' => 10, 'unsigned' => false),
|
|
|
18 |
'name' => array('type' => 'string', 'null' => true, 'collate' => 'latin1_swedish_ci', 'charset' => 'latin1'),
|
|
|
19 |
'indexes' => array(
|
|
|
20 |
'PRIMARY' => array('column' => 'id', 'unique' => 1)
|
|
|
21 |
),
|
|
|
22 |
'tableParameters' => array('charset' => 'latin1', 'collate' => 'latin1_swedish_ci', 'engine' => 'InnoDB')
|
|
|
23 |
);
|
|
|
24 |
|
|
|
25 |
/**
|
|
|
26 |
* Records
|
|
|
27 |
*
|
|
|
28 |
* @var array
|
|
|
29 |
*/
|
|
|
30 |
public $records = array(
|
|
|
31 |
array(
|
|
|
32 |
'id' => 1,
|
|
|
33 |
'parent_id' => 1,
|
|
|
34 |
'lft' => 1,
|
|
|
35 |
'rght' => 1,
|
|
|
36 |
'name' => 'Lorem ipsum dolor sit amet'
|
|
|
37 |
),
|
|
|
38 |
);
|
|
|
39 |
|
|
|
40 |
}
|