| Total Complexity | 2 |
| Total Lines | 34 |
| Duplicated Lines | 0 % |
| Changes | 1 | ||
| Bugs | 0 | Features | 0 |
| 1 | <?php |
||
| 17 | class RecordConverter extends \Tests\Base |
||
| 18 | { |
||
| 19 | /** |
||
| 20 | * Initialize test. |
||
| 21 | */ |
||
| 22 | public function testInitialize() |
||
| 23 | { |
||
| 24 | $dbCommand = \App\Db::getInstance('admin')->createCommand(); |
||
| 25 | $dbCommand->insert( |
||
| 26 | 'a_yf_record_converter', |
||
| 27 | [ |
||
| 28 | 'name' => 'Record converter test', |
||
| 29 | 'status' => 1, |
||
| 30 | 'source_module' => 89, |
||
| 31 | 'destiny_module' => 90, |
||
| 32 | 'field_mapping' => \App\Json::encode( |
||
| 33 | ['auto'] |
||
| 34 | ), |
||
| 35 | 'inv_field_mapping' => \App\Json::encode( |
||
| 36 | ['auto'] |
||
| 37 | ), |
||
| 38 | 'show_in_list' => 1, |
||
| 39 | 'show_in_detail' => 1, |
||
| 40 | ] |
||
| 41 | )->execute(); |
||
| 42 | $this->assertTrue(\App\RecordConverter::isActive('SQuotes', 'Detail')); |
||
| 43 | } |
||
| 44 | |||
| 45 | /** |
||
| 46 | * Process test. |
||
| 47 | */ |
||
| 48 | public function testProcess() |
||
| 51 | // $id = (new \App\Db\Query())->select(['squotesid'])->from('u_#__squotes')->scalar(); |
||
| 52 | // if ($id) { |
||
| 68 |