// Spec: civicrm_api3_create_success($values = 1, $params = array(), $entity = NULL, $action = NULL)
return civicrm_api3_create_success($returnValues, $params, 'System', 'Check');
-}
\ No newline at end of file
+}
+
+/**
+ * System.Get API
+ *
+ * @param arary $params
+ */
+function civicrm_api3_system_get($params) {
+ $returnValues = array(
+ array(
+ 'version' => CRM_Utils_System::version(),
+ 'uf' => CIVICRM_UF,
+ ),
+ );
+ return civicrm_api3_create_success($returnValues, $params, 'System', 'get');
+}
$this->assertTrue(NULL === CRM_Core_BAO_Cache::getItem(self::TEST_CACHE_GROUP, self::TEST_CACHE_PATH));
}
+
+ function testSystemGet() {
+ $result = $this->callAPISuccess('system', 'get', array());
+ $this->assertRegExp('/^[0-9]+\.[0-9]+\.[0-9a-z\-]+$/', $result['values'][0]['version']);
+ $this->assertEquals('UnitTests', $result['values'][0]['uf']);
+ }
}