提交 11934342 编写于 作者: K kirl.liu

Zip code change path

Signed-off-by: Nkirl.liu <kirl.liu@huawei.com>
上级 5467f405
...@@ -25,7 +25,6 @@ group("aafwk_standard") { ...@@ -25,7 +25,6 @@ group("aafwk_standard") {
"actsabilitydistributetest:ActsAbilityDistributeTest", "actsabilitydistributetest:ActsAbilityDistributeTest",
"actsabilitydistributetest:ActsAbilityDistributeTest", "actsabilitydistributetest:ActsAbilityDistributeTest",
"actsabilitymanageretstest:ActsAbilityManagerEtsTest", "actsabilitymanageretstest:ActsAbilityManagerEtsTest",
"amsZipfileUnzipfileST:ActsZlibTest",
"amsabilitymanager/amsMissionSnapshotTest:ActsAmsMissionSnapshotTest", "amsabilitymanager/amsMissionSnapshotTest:ActsAmsMissionSnapshotTest",
"amsabilitymanager/amsMissionSnapshotTestSingleton:ActsAmsMissionSnapshotTestSingleton", "amsabilitymanager/amsMissionSnapshotTestSingleton:ActsAmsMissionSnapshotTestSingleton",
"amsabilitymanager/amsMissionSnapshotTestSingletonS:ActsAmsMissionSnapshotTestSingletonS", "amsabilitymanager/amsMissionSnapshotTestSingletonS:ActsAmsMissionSnapshotTestSingletonS",
......
*.iml
.gradle
/local.properties
/.idea/caches
/.idea/libraries
/.idea/modules.xml
/.idea/workspace.xml
/.idea/navEditor.xml
/.idea/assetWizardSettings.xml
.DS_Store
/build
/captures
.externalNativeBuild
/entry/.preview
.cxx
/node_modules
<?xml version="1.0" encoding="UTF-8"?>
<project version="4">
<component name="CompilerConfiguration">
<bytecodeTargetLevel target="11" />
</component>
</project>
\ No newline at end of file
<?xml version="1.0" encoding="UTF-8"?>
<project version="4">
<component name="GradleMigrationSettings" migrationVersion="1" />
<component name="GradleSettings">
<option name="linkedExternalProjectsSettings">
<GradleProjectSettings>
<option name="testRunner" value="PLATFORM" />
<option name="distributionType" value="LOCAL" />
<option name="externalProjectPath" value="$PROJECT_DIR$" />
<option name="gradleHome" value="E:\DevEco Studio 3.0.0.800\tools\gradle" />
<option name="gradleJvm" value="#JAVA_INTERNAL" />
<option name="modules">
<set>
<option value="$PROJECT_DIR$" />
<option value="$PROJECT_DIR$/entry" />
</set>
</option>
<option name="resolveModulePerSourceSet" value="false" />
<option name="useQualifiedModuleNames" value="false" />
</GradleProjectSettings>
</option>
</component>
</project>
\ No newline at end of file
<?xml version="1.0" encoding="UTF-8"?>
<project version="4">
<component name="RemoteRepositoriesConfiguration">
<remote-repository>
<option name="id" value="central" />
<option name="name" value="Maven Central repository" />
<option name="url" value="https://repo1.maven.org/maven2" />
</remote-repository>
<remote-repository>
<option name="id" value="jboss.community" />
<option name="name" value="JBoss Community repository" />
<option name="url" value="https://repository.jboss.org/nexus/content/repositories/public/" />
</remote-repository>
<remote-repository>
<option name="id" value="maven2" />
<option name="name" value="maven2" />
<option name="url" value="https://developer.huawei.com/repo/" />
</remote-repository>
<remote-repository>
<option name="id" value="maven" />
<option name="name" value="maven" />
<option name="url" value="https://repo.huaweicloud.com/repository/maven/" />
</remote-repository>
</component>
</project>
\ No newline at end of file
<?xml version="1.0" encoding="UTF-8"?>
<project version="4">
<component name="ProjectRootManager" version="2" languageLevel="JDK_1_8" default="true" project-jdk-name="1.8" project-jdk-type="JavaSDK" />
</project>
\ No newline at end of file
{
"app": {
"bundleName": "com.example.amsZipfileUnzipfileST",
"vendor": "example",
"version": {
"code": 1000000,
"name": "1.0.0"
}
},
"deviceConfig": {},
"module": {
"package": "com.example.amsZipfileUnzipfileST",
"name": ".MyApplication",
"mainAbility": "com.example.amsZipfileUnzipfileST.MainAbility",
"deviceType": [
"phone",
"tablet",
"tv",
"wearable"
],
"distro": {
"deliveryWithInstall": true,
"moduleName": "entry",
"moduleType": "entry",
"installationFree": false
},
"abilities": [
{
"skills": [
{
"entities": [
"entity.system.home"
],
"actions": [
"action.system.home"
]
}
],
"visible": true,
"name": "com.example.amsZipfileUnzipfileST.MainAbility",
"icon": "$media:icon",
"description": "$string:mainability_description",
"label": "$string:entry_MainAbility",
"type": "page",
"launchType": "standard"
}
],
"js": [
{
"pages": [
"pages/index/index"
],
"name": "default",
"window": {
"designWidth": 720,
"autoDesignWidth": true
}
}
],
"reqPermissions": [
{
"name":"ohos.permission.GET_BUNDLE_INFO_PRIVILEGED",
"reason":"need use ohos.permission.GET_BUNDLE_INFO_PRIVILEGED"
},
{
"name":"ohos.permission.INSTALL_BUNDLE",
"reason":"need use ohos.permission.INSTALL_BUNDLE"
},
{
"name":"ohos.permission.GET_BUNDLE_INFO",
"reason":"need use ohos.permission.GET_BUNDLE_INFO"
},
{
"name":" ohos.permission.MANAGE_MISSIONS",
"reason":"need use ohos.permission.MANAGE_MISSIONS"
},
{
"name":"ohos.permission.CHANGE_ABILITY_ENABLED_STATE",
"reason":"need use ohos.permission.CHANGE_ABILITY_ENABLED_STATE"
},
{
"name":"ohos.permission.REMOVE_CACHE_FILES",
"reason":"need use ohos.permission.REMOVE_CACHE_FILES"
},
{
"name":"ohos.permission.LISTEN_BUNDLE_CHANGE",
"reason":"need use ohos.permission.LISTEN_BUNDLE_CHANGE"
}
]
}
}
\ No newline at end of file
/*
* Copyright (c) 2021 Huawei Device Co., Ltd.
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
export default {
onCreate() {
console.info('AceApplication onCreate');
},
onDestroy() {
console.info('AceApplication onDestroy');
}
};
.container {
flex-direction: column;
justify-content: center;
align-items: center;
width: 100%;
height: 100%;
}
.title {
font-size: 40px;
color: #000000;
opacity: 0.9;
}
@media screen and (device-type: tablet) and (orientation: landscape) {
.title {
font-size: 100px;
}
}
@media screen and (device-type: wearable) {
.title {
font-size: 28px;
color: #FFFFFF;
}
}
@media screen and (device-type: tv) {
.container {
background-image: url("/common/images/Wallpaper.png");
background-size: cover;
background-repeat: no-repeat;
background-position: center;
}
.title {
font-size: 100px;
color: #FFFFFF;
}
}
@media screen and (device-type: phone) and (orientation: landscape) {
.title {
font-size: 60px;
}
}
/*
* Copyright (C) 2021 Huawei Device Co., Ltd.
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
require('./ContextJsunit.test.js')
{
"strings": {
"hello": "Hello",
"world": "World"
}
}
\ No newline at end of file
{
"strings": {
"hello": "您好",
"world": "世界"
}
}
\ No newline at end of file
<div class="container">
<text class="title">
{{ $t('strings.hello') }} {{ title }}
</text>
</div>
/*
* Copyright (C) 2021 Huawei Device Co., Ltd.
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
import file from '@system.file'
import {Core, ExpectExtend, ReportExtend} from 'deccjsunit/index'
const injecttRef = Object.getPrototypeOf(global) || global
injecttRef.regeneratorRuntime = require('@babel/runtime/regenerator')
export default{
data: {
title: ""
},
onInit() {
this.title = this.$t('strings.world');
},
onShow() {
console.info('onShow finish')
const core = Core.getInstance()
const expectExtend = new ExpectExtend({
'id': 'extend'
})
core.addService('expect', expectExtend)
core.init()
const configService = core.getDefaultService('config')
configService.setConfig(this)
require('../../../test/List.test.js')
core.execute()
},
onReady() {
},
}
...@@ -18,7 +18,7 @@ group("appexecfwk") { ...@@ -18,7 +18,7 @@ group("appexecfwk") {
if (is_standard_system) { if (is_standard_system) {
deps = [ deps = [
"bundle_standard:bundle_standard", "bundle_standard:bundle_standard",
"zlib/actszlibtest:ActsZlibTest", "zlib:zlib",
] ]
} }
} }
...@@ -11,21 +11,14 @@ ...@@ -11,21 +11,14 @@
# See the License for the specific language governing permissions and # See the License for the specific language governing permissions and
# limitations under the License. # limitations under the License.
import("//test/xts/tools/build/suite.gni") import("//build/ohos_var.gni")
ohos_js_hap_suite("ActsZlibTest") { group("zlib") {
hap_profile = "./entry/src/main/config.json" testonly = true
deps = [ if (is_standard_system) {
":hjs_demo_js_assets", deps = [
":hjs_demo_resources", "actszipfileandunzipfiletest:actszipfileandunzipfiletest",
] "actszlibtest:ActsZlibTest",
certificate_profile = "./signature/openharmony_sx.p7b" ]
hap_name = "ActsZipZlibTest" }
}
ohos_js_assets("hjs_demo_js_assets") {
source_dir = "./entry/src/main/js/default"
}
ohos_resources("hjs_demo_resources") {
sources = [ "./entry/src/main/js/resources" ]
hap_profile = "./entry/src/main/config.json"
} }
...@@ -13,14 +13,14 @@ ...@@ -13,14 +13,14 @@
import("//test/xts/tools/build/suite.gni") import("//test/xts/tools/build/suite.gni")
ohos_js_hap_suite("ActsZlibTest") { ohos_js_hap_suite("actszipfileandunzipfiletest") {
hap_profile = "./entry/src/main/config.json" hap_profile = "./entry/src/main/config.json"
deps = [ deps = [
":hjs_demo_js_assets", ":hjs_demo_js_assets",
":hjs_demo_resources", ":hjs_demo_resources",
] ]
certificate_profile = "./signature/openharmony_sx.p7b" certificate_profile = "./signature/openharmony_sx.p7b"
hap_name = "ActsZlibTest" hap_name = "actszipfileandunzipfiletest"
} }
ohos_js_assets("hjs_demo_js_assets") { ohos_js_assets("hjs_demo_js_assets") {
source_dir = "./entry/src/main/js/default" source_dir = "./entry/src/main/js/default"
......
{ {
"description": "Configuration for hjunit demo Tests", "description": "Configuration for hjunit demo Tests",
"driver": { "driver": {
"type": "JSUnitTest", "type": "JSUnitTest",
"test-timeout": "60000", "test-timeout": "60000",
"package": "com.example.amsZipfileUnzipfileST", "package": "com.example.amsZipfileUnzipfileST",
"shell-timeout": "60000" "shell-timeout": "60000"
}, },
"kits": [ "kits": [
{ {
"test-file-name": [ "test-file-name": [
"ActsZipZlibTest.hap" "actszipfileandunzipfiletest.hap"
], ],
"type": "AppInstallKit", "type": "AppInstallKit",
"cleanup-apps": true "cleanup-apps": true
} }
] ]
} }
{ {
"app": { "app": {
"bundleName": "com.example.amsZipfileUnzipfileST", "bundleName": "com.example.amsZipfileUnzipfileST",
"vendor": "example", "vendor": "example",
"version": { "version": {
"code": 1000000, "code": 1,
"name": "1.0.0" "name": "1.0"
} },
}, "apiVersion": {
"deviceConfig": {}, "compatible": 4,
"module": { "target": 5,
"package": "com.example.amsZipfileUnzipfileST", "releaseType": "Beta1"
"name": ".MyApplication", }
"mainAbility": "com.example.amsZipfileUnzipfileST.MainAbility", },
"deviceType": [ "deviceConfig": {},
"phone", "module": {
"tablet", "package": "com.example.amsZipfileUnzipfileST",
"tv", "name": ".MyApplication",
"wearable" "deviceType": [
], "phone"
"distro": { ],
"deliveryWithInstall": true, "distro": {
"moduleName": "entry", "deliveryWithInstall": true,
"moduleType": "entry", "moduleName": "entry",
"installationFree": false "moduleType": "entry"
}, },
"abilities": [ "abilities": [
{ {
"skills": [ "skills": [
{ {
"entities": [ "entities": [
"entity.system.home" "entity.system.home",
], "flag.home.intent.from.system"
"actions": [ ],
"action.system.home" "actions": [
] "action.system.home"
} ]
], }
"visible": true, ],
"name": "com.example.amsZipfileUnzipfileST.MainAbility", "name": "com.example.amsZipfileUnzipfileST.MainAbility",
"icon": "$media:icon", "icon": "$media:icon",
"description": "$string:mainability_description", "description": "$string:mainability_description",
"label": "$string:entry_MainAbility", "label": "$string:app_name",
"type": "page", "type": "page",
"launchType": "standard" "launchType": "standard",
} "visible": true
], }
"js": [ ],
{ "reqPermissions": [
"pages": [ {
"pages/index/index" "name": "ohos.permission.INSTALL_BUNDLE",
], "reason": "need use ohos.permission.INSTALL_BUNDLE"
"name": "default", },
"window": { {
"designWidth": 720, "name":"ohos.permission.GET_BUNDLE_INFO_PRIVILEGED",
"autoDesignWidth": true "reason":"need use ohos.permission.GET_BUNDLE_INFO_PRIVILEGED"
} },
} {
], "name":"ohos.permission.GET_BUNDLE_INFO",
"reqPermissions": [ "reason":"need use ohos.permission.GET_BUNDLE_INFO"
},
{ {
"name":"ohos.permission.GET_BUNDLE_INFO_PRIVILEGED", "name":"ohos.permission.CHANGE_ABILITY_ENABLED_STATE",
"reason":"need use ohos.permission.GET_BUNDLE_INFO_PRIVILEGED" "reason":"need use ohos.permission.CHANGE_ABILITY_ENABLED_STATE"
}, },
{ {
"name":"ohos.permission.INSTALL_BUNDLE", "name":"ohos.permission.REMOVE_CACHE_FILES",
"reason":"need use ohos.permission.INSTALL_BUNDLE" "reason":"need use ohos.permission.REMOVE_CACHE_FILES"
}, },
{ {
"name":"ohos.permission.GET_BUNDLE_INFO", "name":"ohos.permission.LISTEN_BUNDLE_CHANGE",
"reason":"need use ohos.permission.GET_BUNDLE_INFO" "reason":"need use ohos.permission.LISTEN_BUNDLE_CHANGE"
}, }
{ ],
"name":" ohos.permission.MANAGE_MISSIONS", "js": [
"reason":"need use ohos.permission.MANAGE_MISSIONS" {
}, "pages": [
{ "pages/index/index"
"name":"ohos.permission.CHANGE_ABILITY_ENABLED_STATE", ],
"reason":"need use ohos.permission.CHANGE_ABILITY_ENABLED_STATE" "name": "default",
}, "window": {
{ "designWidth": 720,
"name":"ohos.permission.REMOVE_CACHE_FILES", "autoDesignWidth": false
"reason":"need use ohos.permission.REMOVE_CACHE_FILES" }
}, }
{ ]
"name":"ohos.permission.LISTEN_BUNDLE_CHANGE", }
"reason":"need use ohos.permission.LISTEN_BUNDLE_CHANGE" }
}
]
}
}
\ No newline at end of file
/* /*
* Copyright (c) 2021 Huawei Device Co., Ltd. * Copyright (c) 2021 Huawei Device Co., Ltd.
* Licensed under the Apache License, Version 2.0 (the "License"); * Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License. * you may not use this file except in compliance with the License.
* You may obtain a copy of the License at * You may obtain a copy of the License at
* *
* http://www.apache.org/licenses/LICENSE-2.0 * http://www.apache.org/licenses/LICENSE-2.0
* *
* Unless required by applicable law or agreed to in writing, software * Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS, * distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and * See the License for the specific language governing permissions and
* limitations under the License. * limitations under the License.
*/ */
export default { export default {
onCreate() { onCreate() {
console.info('AceApplication onCreate'); console.info('AceApplication onCreate');
}, },
onDestroy() { onDestroy() {
console.info('AceApplication onDestroy'); console.info('AceApplication onDestroy');
} }
}; };
.container {
flex-direction: column;
justify-content: center;
align-items: center;
}
.title {
font-size: 100px;
}
<div class="container"> <div class="container">
<text class="title"> <text class="title">
{{ $t('strings.hello') }} {{ title }} {{ title }}
</text> </text>
</div> </div>
/* /*
* Copyright (C) 2021 Huawei Device Co., Ltd. * Copyright (c) 2021 Huawei Device Co., Ltd.
* Licensed under the Apache License, Version 2.0 (the "License"); * Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License. * you may not use this file except in compliance with the License.
* You may obtain a copy of the License at * You may obtain a copy of the License at
...@@ -12,35 +12,34 @@ ...@@ -12,35 +12,34 @@
* See the License for the specific language governing permissions and * See the License for the specific language governing permissions and
* limitations under the License. * limitations under the License.
*/ */
import file from '@system.file' import {Core, ExpectExtend} from 'deccjsunit/index'
import {Core, ExpectExtend, ReportExtend} from 'deccjsunit/index'
const injecttRef = Object.getPrototypeOf(global) || global const injectRef = Object.getPrototypeOf(global) || global
injecttRef.regeneratorRuntime = require('@babel/runtime/regenerator') injectRef.regeneratorRuntime = require('@babel/runtime/regenerator')
export default{ export default {
data: { data: {
title: "" title: 'Test MetaData'
}, },
onInit() { onInit() {
this.title = this.$t('strings.world'); this.title = 'zip and unzip';
}, },
onShow() { onShow() {
console.info('onShow finish') console.info('onReady finish')
const core = Core.getInstance() const core = Core.getInstance()
const expectExtend = new ExpectExtend({ const expectExtend = new ExpectExtend({
'id': 'extend' 'id': 'extend'
}) })
core.addService('expect', expectExtend) core.addService('expect', expectExtend)
core.init() core.init()
const configService = core.getDefaultService('config') const configService = core.getDefaultService('config')
configService.setConfig(this) configService.setConfig(this)
require('../../../test/List.test.js') require('../../../test/List.test')
core.execute() core.execute()
}, },
onReady() { onReady() {
}, },
onBackPress(){
}
} }
{ {
"string": [ "string": [
{ {
"name": "entry_MainAbility", "name": "app_name",
"value": "entry_MainAbility" "value": "actsbmsmetadatatest"
}, },
{ {
"name": "mainability_description", "name": "mainability_description",
"value": "JS_Empty Ability" "value": "JS_Phone_Empty Feature Ability"
} }
] ]
} }
\ No newline at end of file
...@@ -12,4 +12,4 @@ ...@@ -12,4 +12,4 @@
* See the License for the specific language governing permissions and * See the License for the specific language governing permissions and
* limitations under the License. * limitations under the License.
*/ */
require('./ContextJsunit.test.js') require('./actszipfileandunzipfiletest.test.js')
...@@ -1539,7 +1539,7 @@ it('ACTS_ZipFile_2600', 0, async function (done) { ...@@ -1539,7 +1539,7 @@ it('ACTS_ZipFile_2600', 0, async function (done) {
}); });
try { try {
var options = {}; var options = {};
options.memLevel = zlib.MemLevel.MEM_LEVEL_MIN_MEMLEVEL; options.memLevel = zlib.MemLevel.MEM_LEVEL_MIN;
await zlib.zipFile(path, zipDest, options, await zlib.zipFile(path, zipDest, options,
(err, data) => { (err, data) => {
var zipStat = fileio.statSync(zipDest); var zipStat = fileio.statSync(zipDest);
...@@ -1604,7 +1604,7 @@ it('ACTS_ZipFile_2700', 0, async function (done) { ...@@ -1604,7 +1604,7 @@ it('ACTS_ZipFile_2700', 0, async function (done) {
}); });
try { try {
var options = {}; var options = {};
options.memLevel = zlib.MemLevel.MEM_LEVEL_MAX_MEMLEVEL; options.memLevel = zlib.MemLevel.MEM_LEVEL_MAX;
await zlib.zipFile(path, zipDest, options, await zlib.zipFile(path, zipDest, options,
(err, data) => { (err, data) => {
var zipStat = fileio.statSync(zipDest); var zipStat = fileio.statSync(zipDest);
...@@ -1669,7 +1669,7 @@ it('ACTS_ZipFile_2800', 0, async function (done) { ...@@ -1669,7 +1669,7 @@ it('ACTS_ZipFile_2800', 0, async function (done) {
}); });
try { try {
var options = {}; var options = {};
options.memLevel = zlib.MemLevel.MEM_LEVEL_DEFAULT_MEMLEVEL; options.memLevel = zlib.MemLevel.MEM_LEVEL_DEFAULT;
await zlib.zipFile(path, zipDest, options, await zlib.zipFile(path, zipDest, options,
(err, data) => { (err, data) => {
var zipStat = fileio.statSync(zipDest); var zipStat = fileio.statSync(zipDest);
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册