Explorar o código

Modified - modifying the test of function get_language_file_as_xml.

Ricardo Rodriguez %!s(int64=15) %!d(string=hai) anos
pai
achega
9232813887
Modificáronse 1 ficheiros con 7 adicións e 1 borrados
  1. 7 1
      tests/main/conference/get_translation.lib.test.php

+ 7 - 1
tests/main/conference/get_translation.lib.test.php

@@ -4,8 +4,14 @@ require_once(api_get_path(SYS_CODE_PATH).'conference/get_translation.lib.php');
 class TestGetTranslation extends UnitTestCase {
 
 	function testget_language_file_as_xml(){
+		ob_start();
 		$res=get_language_file_as_xml($language='english');
-		$this->assertTrue(($res));
+		ob_end_clean();
+		if(is_string($res)) {
+			$this->assertFalse($res);
+		} else {
+		$this->assertTrue($res);
+		}
 		//var_dump($res);
 	}
 }