Welcome Guest, Not a member yet? Register   Sign In
ci-phpunit-test for CodeIgniter 3.0
#85

Hello everyone,

I'm trying to test GroceryCRUD pages with ci-phpunit-test, but I have strange result.

PHP Code:
class Examples_test extends TestCase
{
    public function 
test_index()
    {
            
// Test OK
        
$this->request('GET''examples/customers_management');
        
$this->assertResponseCode(200);
        
        
// Test ~= NOK
        
$this->ajaxRequest('POST''examples/customers_management/ajax_list', [
            
'page' => 1,
            
'per_page' => 10,
            
'oder_by' => ['contactLastName''asc'],
            
'search_field' => ['contactLastName'],
            
'search_text' => ['ben'],
        ]);
        
$this->assertResponseCode(200);
    }



When I use ajaxRequest, I doesn't show assertion result. I show the ajax result in my console.

Any idea ?

Thanks

PS: thank you so much kenjis and John, Your libraries are fantastic. I use them every job day.
Reply


Messages In This Thread
ci-phpunit-test for CodeIgniter 3.0 - by kenjis - 05-09-2015, 11:33 PM
RE: ci-phpunit-test for CodeIgniter 3.0 - by bvrignaud - 09-14-2017, 10:22 AM



Theme © iAndrew 2016 - Forum software by © MyBB