提交 c11f77bf 编写于 作者: O openharmony_ci 提交者: Gitee

!1235 fms_xts

Merge pull request !1235 from blackleon/fms_1129
......@@ -17,7 +17,7 @@ group("formmanager") {
testonly = true
if (is_standard_system) {
deps = [
"formsystemtesthost/FormFuzzTest:FormFuzzTest",
"formsystemtesthost/actsformfuzztest:ActsFormFuzzTest",
"formsystemtesthost/actsformsoneandonetest:ActsFormsOneAndOneTest",
"formsystemtesthost/actsformsoneandtwotest:ActsFormsOneAndTwoTest",
"formsystemtesthost/actsformszeroandonetest:ActsFormsZeroAndOneTest",
......
......@@ -13,14 +13,14 @@
import("//test/xts/tools/build/suite.gni")
ohos_js_hap_suite("FormFuzzTest") {
ohos_js_hap_suite("ActsFormFuzzTest") {
hap_profile = "./entry/src/main/config.json"
deps = [
":hjs_demo_js_assets",
":hjs_demo_resources",
]
certificate_profile = "./signature/openharmony_sx.p7b"
hap_name = "FormFuzzTest"
hap_name = "ActsFormFuzzTest"
}
ohos_js_assets("hjs_demo_js_assets") {
source_dir = "./entry/src/main/js/default"
......
......@@ -2,14 +2,14 @@
"description": "Configuration for hjunit demo Tests",
"driver": {
"type": "JSUnitTest",
"test-timeout": "360000",
"test-timeout": "420000",
"package": "com.example.formfuzztest",
"shell-timeout": "60000"
},
"kits": [
{
"test-file-name": [
"FormFuzzTest.hap"
"ActsFormFuzzTest.hap"
],
"type": "AppInstallKit",
"cleanup-apps": true
......
......@@ -13,11 +13,11 @@
* limitations under the License.
*/
require('./FormFuzzTestArray.test.js')
require('./FormFuzzTestBool.test.js')
require('./FormFuzzTestFunction.test.js')
require('./FormFuzzTestNull.test.js')
require('./FormFuzzTestNum.test.js')
require('./FormFuzzTestObject.test.js')
require('./FormFuzzTestString.test.js')
require('./FormFuzzTestUndefined.test.js')
\ No newline at end of file
require('./FormFuzzArray.test.js')
require('./FormFuzzBool.test.js')
require('./FormFuzzFunction.test.js')
require('./FormFuzzNull.test.js')
require('./FormFuzzNum.test.js')
require('./FormFuzzObject.test.js')
require('./FormFuzzString.test.js')
require('./FormFuzzUndefined.test.js')
......@@ -12,6 +12,9 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
export const REPEAT_COUNT = 2;
var RANDOM_BEGIN_POSITION = 0;
var RANDOM_BEGIN_POSITION_A = 2;
var STRING_RANDOM_LENGTH = 2064;
......@@ -68,31 +71,31 @@ const stringTest = function() {
}
console.log("The stringTest of this fuzzTest random:" + res);
return res;
}
};
// return number random, the number length is: [Number.MIN_SAFE_INTEGER, Number.MAX_SAFE_INTEGER]
const numberTest = function() {
console.log("The numberTest of this fuzzTest random" );
return getIntegerRandom(Number.MIN_SAFE_INTEGER, Number.MAX_SAFE_INTEGER + 1);
}
};
// return boolean random, the boolean value is: 0->(false), 1->(true)
const booleanTest = function() {
console.log("The booleanTest of this fuzzTest random" );
return Boolean(getIntegerRandom(RANDOM_BEGIN_POSITION, BOOLEAN_RANDOM_LENGTH));
}
};
// null
const nullTest = function() {
console.log("The nullTest of this fuzzTest random" );
return null;
}
};
// undefined
const undefinedTest = function() {
console.log("The undefinedTest of this fuzzTest random" );
return undefined;
}
};
// return array random, the array value is: string,number,bool
const arrayTest = function() {
......@@ -120,7 +123,7 @@ const arrayTest = function() {
}
console.log("The arrayTest of this fuzzTest random:" + arrValue);
return arrValue;
}
};
// return objectTest random, the objectTest value is: null, not null
const objectTest = function() {
......@@ -130,7 +133,7 @@ const objectTest = function() {
console.log("The objectTest of this fuzzTest random" );
return getIntegerRandom(RANDOM_BEGIN_POSITION, OBJECT_RANDOM_LENGTH) ? objectA: objectB;
}
};
// return functionTest random, the functionTest value is: null, not null
const functionTest = function() {
......@@ -139,7 +142,7 @@ const functionTest = function() {
console.log("The functionTest of this fuzzTest random" );
return getIntegerRandom(RANDOM_BEGIN_POSITION, FUNCTION_RANDOM_LENGTH) ? functionA: functionB;
}
};
export {
stringTest, numberTest, booleanTest, nullTest, undefinedTest, objectTest, arrayTest, functionTest
......
......@@ -66,28 +66,6 @@
}
]
}
},
{
"name": "FormC_Js002",
"description": "form_description",
"isDefault": true,
"type": "JS",
"colorMode": "auto",
"supportDimensions":[ "1*2", "2*2" ],
"defaultDimension": "1*2",
"updateEnabled": true,
"updateDuration": 1,
"scheduledUpdateTime": "10:30",
"jsComponentName": "card",
"formVisibleNotify" : true,
"metaData": {
"customizeData": [
{
"name": "originWidgetName",
"value": "myTest"
}
]
}
}
]
}
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册