Depending on how your ajax response is generated, this can be easy or harder. If you use a controller to generate a response, you can simply call the corresponding function in the unit test and check the returned HTML / XML. For example, if responses are generated by function calls on a controller object, for example:
$htmlResponse = $controller->buildPage($_REQUEST);
then you can answer unit test as follows:
$expected = "<html>whatever html you expect</html>";
$test_request = array(...);
$actual = $controller->buildPage($test_request);
$this->assertEquals($expected, $actual);
, , - AJAX , , - :
$_POST['parameter1'] = "test value";
ob_start();
include('ajax_page.php');
$actual = ob_get_clean();
$expected = "<html>expected html as above</html>";
$this->assertEquals($expected, $actual);
PHPUnit assertTag , HTML XML , , - , , .
, , , , , ( ), ( HTML XML). , AJAX, . , AJAX- , JS.