--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileHandle_close</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileHandle_close
+//==== LABEL Check if FileHandle::close() method works properly
+//==== SPEC Tizen Web API:IO:Filesystem:FileHandle:close M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P1
+//==== TEST_CRITERIA MR MNA
+
+test(function () {
+ var fileHandleWrite, retVal;
+
+ add_result_callback(function () {
+ try {
+ tizen.filesystem.deleteFile("documents/file");
+ } catch (err) {
+ }
+ });
+
+ fileHandleWrite = tizen.filesystem.openFile("documents/file", "w");
+ retVal = fileHandleWrite.close();
+ assert_equals(retVal, undefined, "return value should be undefined");
+}, document.title);
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileHandle_closeNonBlocking</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileHandle_closeNonBlocking
+//==== LABEL Check if FileHandle::closeNonBlocking() method works properly
+//==== SPEC Tizen Web API:IO:Filesystem:FileHandle:closeNonBlocking M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P1
+//==== ONLOAD_DELAY 90
+//==== TEST_CRITERIA MR MMINA
+
+var t = async_test(document.title), writeStringNonBlockingSuccess, writeStringNonBlockingError,
+ fileHandleWrite, retVal, content = "Lorem ipsum dolor sit amet...";
+
+t.step(function () {
+ add_result_callback(function () {
+ try {
+ fileHandleWrite.close();
+ tizen.filesystem.deleteFile("documents/file");
+ } catch (err) {
+ }
+ });
+
+ writeStringNonBlockingSuccess = t.step_func(function (bytesCount) {
+ });
+
+ writeStringNonBlockingError = t.step_func(function (error) {
+ assert_unreached("writeStringNonBlocking() error callback invoked: name:" + error.name + "msg:" + error.message);
+ });
+
+ fileHandleWrite = tizen.filesystem.openFile("documents/file", "w");
+ fileHandleWrite.writeStringNonBlocking(content, writeStringNonBlockingSuccess, writeStringNonBlockingError);
+ retVal = fileHandleWrite.closeNonBlocking();
+ assert_equals(retVal, undefined, "return value should be undefined");
+ t.done();
+});
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileHandle_closeNonBlocking_errorCallback_invalid_cb</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileHandle_closeNonBlocking_errorCallback_invalid_cb
+//==== LABEL Check if FileHandle::closeNonBlocking() method throws exception when errorCallback is invalid
+//==== SPEC Tizen Web API:IO:Filesystem:FileHandle:closeNonBlocking M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P2
+//==== ONLOAD_DELAY 90
+//==== TEST_CRITERIA MTCB
+
+var t = async_test(document.title), closeNonBlockingSuccess, invalidCallback, fileHandleWrite;
+
+t.step(function () {
+ add_result_callback(function () {
+ try {
+ fileHandleWrite.close();
+ tizen.filesystem.deleteFile("documents/file");
+ } catch (err) {
+ }
+ });
+
+ closeNonBlockingSuccess = t.step_func(function () {
+ assert_unreached("Should not be invoked closeNonBlocking SuccessCallback");
+ });
+
+ invalidCallback = {
+ onerror: t.step_func(function (error) {
+ assert_unreached("Invalid callback invoked");
+ })
+ };
+
+ fileHandleWrite = tizen.filesystem.openFile("documents/file", "w");
+ assert_throws(TYPE_MISMATCH_EXCEPTION, function () {
+ fileHandleWrite.closeNonBlocking(closeNonBlockingSuccess, invalidCallback);
+ }, "given incorrect errorCallback");
+ t.done();
+});
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileHandle_closeNonBlocking_exist</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileHandle_closeNonBlocking_exist
+//==== LABEL Check if FileHandle::closeNonBlocking() method exists
+//==== SPEC Tizen Web API:IO:Filesystem:FileHandle:closeNonBlocking M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P0
+//==== TEST_CRITERIA ME
+
+test(function () {
+ var fileHandleWrite;
+
+ add_result_callback(function () {
+ try {
+ fileHandleWrite.close();
+ tizen.filesystem.deleteFile("documents/file");
+ } catch (err) {
+ }
+ });
+
+ fileHandleWrite = tizen.filesystem.openFile("documents/file", "w");
+ check_method_exists(fileHandleWrite, "closeNonBlocking");
+}, document.title);
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileHandle_closeNonBlocking_onerror_TypeMismatch</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileHandle_closeNonBlocking_onerror_TypeMismatch
+//==== LABEL Check if FileHandle::closeNonBlocking() method throws exception for wrong type of onerror
+//==== SPEC Tizen Web API:IO:Filesystem:FileHandle:closeNonBlocking M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P2
+//==== ONLOAD_DELAY 90
+//==== TEST_CRITERIA MC
+
+var t = async_test(document.title), closeNonBlockingSuccess, closeNonBlockingError, fileHandleWrite,
+ i, conversionTable, exceptionName = "TypeMismatchError";
+
+t.step(function () {
+ add_result_callback(function () {
+ try {
+ fileHandleWrite.close();
+ tizen.filesystem.deleteFile("documents/file");
+ } catch (err) {
+ }
+ });
+
+ closeNonBlockingSuccess = t.step_func(function () {
+ assert_unreached("Should not be invoked to closeNonBlocking SuccessCallback");
+ });
+
+ fileHandleWrite = tizen.filesystem.openFile("documents/file", "w");
+ conversionTable = getTypeConversionExceptions("functionObject", true);
+ for (i = 0; i < conversionTable.length; i++) {
+ closeNonBlockingError = conversionTable[i][0];
+
+ assert_throws({name: exceptionName}, function () {
+ fileHandleWrite.closeNonBlocking(closeNonBlockingSuccess, closeNonBlockingError);
+ }, exceptionName + " should be thrown - given incorrect errorCallback.");
+ }
+ t.done();
+});
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileHandle_closeNonBlocking_onsuccess_TypeMismatch</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileHandle_closeNonBlocking_onsuccess_TypeMismatch
+//==== LABEL Check if FileHandle::closeNonBlocking() method throws exception for wrong type of onsuccess
+//==== SPEC Tizen Web API:IO:Filesystem:FileHandle:closeNonBlocking M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P2
+//==== ONLOAD_DELAY 90
+//==== TEST_CRITERIA MC
+
+var t = async_test(document.title), closeNonBlockingSuccess, closeNonBlockingError, fileHandleWrite,
+ i, conversionTable, exceptionName = "TypeMismatchError";
+
+t.step(function () {
+ add_result_callback(function () {
+ try {
+ fileHandleWrite.close();
+ tizen.filesystem.deleteFile("documents/file");
+ } catch (err) {
+ }
+ });
+
+ closeNonBlockingError = t.step_func(function (error) {
+ assert_unreached("closeNonBlocking() error callback invoked: name:" + error.name + "msg:" + error.message);
+ });
+
+ fileHandleWrite = tizen.filesystem.openFile("documents/file", "w");
+ conversionTable = getTypeConversionExceptions("functionObject", true);
+ for (i = 0; i < conversionTable.length; i++) {
+ closeNonBlockingSuccess = conversionTable[i][0];
+
+ assert_throws({name: exceptionName}, function () {
+ fileHandleWrite.closeNonBlocking(closeNonBlockingSuccess, closeNonBlockingError);
+ }, exceptionName + " should be thrown - given incorrect successCallback.");
+ }
+ t.done();
+});
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileHandle_closeNonBlocking_successCallback_invalid_cb</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileHandle_closeNonBlocking_successCallback_invalid_cb
+//==== LABEL Check if FileHandle::closeNonBlocking() method throws exception when successCallback is invalid
+//==== SPEC Tizen Web API:IO:Filesystem:FileHandle:closeNonBlocking M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P2
+//==== ONLOAD_DELAY 90
+//==== TEST_CRITERIA MTCB
+
+var t = async_test(document.title), invalidCallback, closeNonBlockingError, fileHandleWrite;
+
+t.step(function () {
+ add_result_callback(function () {
+ try {
+ fileHandleWrite.close();
+ tizen.filesystem.deleteFile("documents/file");
+ } catch (err) {
+ }
+ });
+
+ invalidCallback = {
+ onsuccess: t.step_func(function () {
+ assert_unreached("Invalid callback invoked");
+ })
+ };
+
+ closeNonBlockingError = t.step_func(function (error) {
+ assert_unreached("closeNonBlocking() error callback invoked: name:" + error.name + "msg:" + error.message);
+ });
+
+ fileHandleWrite = tizen.filesystem.openFile("documents/file", "w");
+ assert_throws(TYPE_MISMATCH_EXCEPTION, function () {
+ fileHandleWrite.closeNonBlocking(invalidCallback, closeNonBlockingError);
+ }, "given incorrect successCallback");
+ t.done();
+});
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileHandle_closeNonBlocking_with_onerror</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileHandle_closeNonBlocking_with_onerror
+//==== LABEL Check if FileHandle::closeNonBlocking() method works properly with onerror
+//==== SPEC Tizen Web API:IO:Filesystem:FileHandle:closeNonBlocking M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P1
+//==== ONLOAD_DELAY 90
+//==== TEST_CRITERIA MOA MR
+
+var t = async_test(document.title), writeStringNonBlockingSuccess, writeStringNonBlockingError,
+ closeNonBlockingSuccess, closeNonBlockingError, fileHandleWrite, retVal, content = "Lorem ipsum dolor sit amet...";
+
+t.step(function () {
+ add_result_callback(function () {
+ try {
+ fileHandleWrite.close();
+ tizen.filesystem.deleteFile("documents/file");
+ } catch (err) {
+ }
+ });
+
+ writeStringNonBlockingSuccess = t.step_func(function (bytesCount) {
+ });
+
+ writeStringNonBlockingError = t.step_func(function (error) {
+ assert_unreached("writeStringNonBlocking() error callback invoked: name:" + error.name + "msg:" + error.message);
+ });
+
+ closeNonBlockingSuccess = t.step_func(function () {
+ assert_equals(retVal, undefined, "return value should be undefined");
+ t.done();
+ });
+
+ closeNonBlockingError = t.step_func(function (error) {
+ assert_unreached("closeNonBlocking() error callback invoked: name:" + error.name + "msg:" + error.message);
+ });
+
+ fileHandleWrite = tizen.filesystem.openFile("documents/file", "w");
+ fileHandleWrite.writeStringNonBlocking(content, writeStringNonBlockingSuccess, writeStringNonBlockingError);
+ retVal = fileHandleWrite.closeNonBlocking(closeNonBlockingSuccess, closeNonBlockingError);
+});
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileHandle_close_exist</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileHandle_close_exist
+//==== LABEL Check if FileHandle::close() method exists
+//==== SPEC Tizen Web API:IO:Filesystem:FileHandle:close M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P0
+//==== TEST_CRITERIA ME
+
+test(function () {
+ var fileHandleWrite;
+
+ add_result_callback(function () {
+ try {
+ fileHandleWrite.close();
+ tizen.filesystem.deleteFile("documents/file");
+ } catch (err) {
+ }
+ });
+
+ fileHandleWrite = tizen.filesystem.openFile("documents/file", "w");
+ check_method_exists(fileHandleWrite, "close");
+}, document.title);
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileHandle_close_extra_argument</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileHandle_close_extra_argument
+//==== LABEL Check using FileHandle::close() method with extra argument
+//==== SPEC Tizen Web API:IO:Filesystem:FileHandle:close M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P1
+//==== TEST_CRITERIA MNAEX
+
+test(function () {
+ var extraArgument = [
+ null,
+ undefined,
+ "Tizen",
+ 1,
+ false,
+ ["one", "two"],
+ {argument: 1},
+ function () {}
+ ], i, fileHandleWrite;
+
+ add_result_callback(function () {
+ try {
+ fileHandleWrite.close();
+ tizen.filesystem.deleteFile("documents/file");
+ } catch (err) {
+ }
+ });
+
+ fileHandleWrite = tizen.filesystem.openFile("documents/file", "w");
+ for (i = 0; i < extraArgument.length; i++) {
+ fileHandleWrite.close(extraArgument[i]);
+ fileHandleWrite = tizen.filesystem.openFile("documents/file", "w");
+ }
+}, document.title);
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileHandle_flush</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileHandle_flush
+//==== LABEL Check if FileHandle::flush() method works properly
+//==== SPEC Tizen Web API:IO:Filesystem:FileHandle:flush M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P1
+//==== TEST_CRITERIA MR MNA MNAST
+
+test(function () {
+ var fileHandleWrite, fileHandleRead, fileContents, content = "Lorem ipsum dolor sit amet...", retVal;
+
+ add_result_callback(function () {
+ fileHandleWrite.close();
+ fileHandleRead.close();
+ tizen.filesystem.deleteFile("documents/file");
+ });
+
+ fileHandleWrite = tizen.filesystem.openFile("documents/file", "w");
+ fileHandleRead = tizen.filesystem.openFile("documents/file", "r");
+ fileHandleWrite.writeString(content);
+ retVal = fileHandleWrite.flush();
+ assert_equals(retVal, undefined, "return value should be undefined");
+
+ fileContents = fileHandleRead.readString();
+ assert_equals(fileContents, content, "the flush content is not right");
+}, document.title);
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileHandle_flushNonBlocking</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileHandle_flushNonBlocking
+//==== LABEL Check if FileHandle::flushNonBlocking() method works properly
+//==== SPEC Tizen Web API:IO:Filesystem:FileHandle:flushNonBlocking M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P1
+//==== ONLOAD_DELAY 90
+//==== TEST_CRITERIA MR MMINA MAST
+
+var t = async_test(document.title), writeStringNonBlockingSuccess, writeStringNonBlockingError,
+ readStringNonBlockingSuccess, readStringNonBlockingError,
+ fileHandleWrite, fileHandleRead, retVal, content = "Lorem ipsum dolor sit amet...";
+
+t.step(function () {
+ add_result_callback(function () {
+ try {
+ fileHandleWrite.close();
+ fileHandleRead.close();
+ tizen.filesystem.deleteFile("documents/file");
+ } catch (err) {
+ }
+ });
+
+ writeStringNonBlockingSuccess = t.step_func(function (bytesCount) {
+ });
+
+ writeStringNonBlockingError = t.step_func(function (error) {
+ assert_unreached("writeStringNonBlocking() error callback invoked: name:" + error.name + "msg:" + error.message);
+ });
+
+ readStringNonBlockingSuccess = t.step_func(function (output) {
+ assert_equals(output, content, "The flush content is not right.");
+ t.done();
+ });
+
+ readStringNonBlockingError = t.step_func(function (error) {
+ assert_unreached("readStringNonBlocking() error callback invoked: name:" + error.name + "msg:" + error.message);
+ });
+
+ fileHandleWrite = tizen.filesystem.openFile("documents/file", "w");
+ fileHandleWrite.writeStringNonBlocking(content, writeStringNonBlockingSuccess, writeStringNonBlockingError);
+ retVal = fileHandleWrite.flushNonBlocking();
+ assert_equals(retVal, undefined, "return value should be undefined");
+
+ fileHandleRead = tizen.filesystem.openFile("documents/file", "r");
+ fileHandleRead.readStringNonBlocking(readStringNonBlockingSuccess, readStringNonBlockingError);
+});
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileHandle_flushNonBlocking_errorCallback_invalid_cb</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileHandle_flushNonBlocking_errorCallback_invalid_cb
+//==== LABEL Check if FileHandle::flushNonBlocking() method throws exception when errorCallback is invalid
+//==== SPEC Tizen Web API:IO:Filesystem:FileHandle:flushNonBlocking M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P2
+//==== ONLOAD_DELAY 90
+//==== TEST_CRITERIA MTCB
+
+var t = async_test(document.title), fileHandleWrite, flushNonBlockingSuccess, invalidCallback;
+
+t.step(function () {
+ add_result_callback(function () {
+ fileHandleWrite.close();
+ tizen.filesystem.deleteFile("documents/file");
+ });
+
+ flushNonBlockingSuccess = t.step_func(function () {
+ assert_unreached("Should not be invoked flushNonBlocking SuccessCallback");
+ });
+
+ invalidCallback = {
+ onerror: t.step_func(function (error) {
+ assert_unreached("Invalid callback invoked");
+ })
+ };
+
+ fileHandleWrite = tizen.filesystem.openFile("documents/file", "w");
+ assert_throws(TYPE_MISMATCH_EXCEPTION, function () {
+ fileHandleWrite.flushNonBlocking(flushNonBlockingSuccess, invalidCallback);
+ }, "given incorrect errorCallback");
+ t.done();
+});
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileHandle_flushNonBlocking_errorCallback_invoked_IOError</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileHandle_flushNonBlocking_errorCallback_invoked_IOError
+//==== LABEL Check if errorcallback of FileHandle::flushNonBlocking() method can be invoked if input/output error occurs
+//==== SPEC Tizen Web API:IO:Filesystem:FileHandle:flushNonBlocking M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P2
+//==== ONLOAD_DELAY 90
+//==== TEST_CRITERIA MERRCB
+
+var t = async_test(document.title), writeStringNonBlockingSuccess, writeStringNonBlockingError,
+ fileHandleWrite, flushNonBlockingSuccess, flushNonBlockingError, content = "Lorem ipsum dolor sit amet...";
+
+t.step(function () {
+ add_result_callback(function () {
+ tizen.filesystem.deleteFile("documents/file");
+ });
+
+ writeStringNonBlockingSuccess = t.step_func(function (bytesCount) {
+ });
+
+ writeStringNonBlockingError = t.step_func(function (error) {
+ assert_unreached("writeStringNonBlocking() error callback invoked: name:" + error.name + "msg:" + error.message);
+ });
+
+ flushNonBlockingSuccess = t.step_func(function () {
+ assert_unreached("Should not be invoked flushNonBlocking SuccessCallback");
+ });
+
+ flushNonBlockingError = t.step_func(function (error) {
+ assert_equals(error.name, "IOError", "expect to throw an IOError exception");
+ t.done();
+ });
+
+ fileHandleWrite = tizen.filesystem.openFile("documents/file", "w");
+ fileHandleWrite.writeStringNonBlocking(content, writeStringNonBlockingSuccess, writeStringNonBlockingError);
+ fileHandleWrite.close();
+ fileHandleWrite.flushNonBlocking(flushNonBlockingSuccess, flushNonBlockingError);
+});
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileHandle_flushNonBlocking_exist</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileHandle_flushNonBlocking_exist
+//==== LABEL Check if FileHandle::flushNonBlocking() method exists
+//==== SPEC Tizen Web API:IO:Filesystem:FileHandle:flushNonBlocking M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P0
+//==== TEST_CRITERIA ME
+
+test(function () {
+ var fileHandleWrite;
+
+ add_result_callback(function () {
+ fileHandleWrite.close();
+ tizen.filesystem.deleteFile("documents/file");
+ });
+
+ fileHandleWrite = tizen.filesystem.openFile("documents/file", "w");
+ check_method_exists(fileHandleWrite, "flushNonBlocking");
+}, document.title);
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileHandle_flushNonBlocking_onerror_TypeMismatch</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileHandle_flushNonBlocking_onerror_TypeMismatch
+//==== LABEL Check if FileHandle::flushNonBlocking() method throws exception for wrong type of onerror
+//==== SPEC Tizen Web API:IO:Filesystem:FileHandle:flushNonBlocking M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P2
+//==== ONLOAD_DELAY 90
+//==== TEST_CRITERIA MC
+
+var t = async_test(document.title), fileHandleWrite, flushNonBlockingSuccess,
+ flushNonBlockingError, i, conversionTable, exceptionName = "TypeMismatchError";
+
+t.step(function () {
+ add_result_callback(function () {
+ fileHandleWrite.close();
+ tizen.filesystem.deleteFile("documents/file");
+ });
+
+ flushNonBlockingSuccess = t.step_func(function () {
+ assert_unreached("Should not be invoked to flushNonBlocking Successcallback");
+ });
+
+ fileHandleWrite = tizen.filesystem.openFile("documents/file", "w");
+
+ conversionTable = getTypeConversionExceptions("functionObject", true);
+ for (i = 0; i < conversionTable.length; i++) {
+ flushNonBlockingError = conversionTable[i][0];
+
+ assert_throws({name: exceptionName}, function () {
+ fileHandleWrite.flushNonBlocking(flushNonBlockingSuccess, flushNonBlockingError);
+ }, exceptionName + " should be thrown - given incorrect errorCallback.");
+ }
+ t.done();
+});
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileHandle_flushNonBlocking_onsuccess_TypeMismatch</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileHandle_flushNonBlocking_onsuccess_TypeMismatch
+//==== LABEL Check if FileHandle::flushNonBlocking() method throws exception for wrong type of onsuccess
+//==== SPEC Tizen Web API:IO:Filesystem:FileHandle:flushNonBlocking M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P2
+//==== ONLOAD_DELAY 90
+//==== TEST_CRITERIA MC
+
+var t = async_test(document.title), fileHandleWrite, flushNonBlockingSuccess,
+ flushNonBlockingError, i, conversionTable, exceptionName = "TypeMismatchError";
+
+t.step(function () {
+ add_result_callback(function () {
+ fileHandleWrite.close();
+ tizen.filesystem.deleteFile("documents/file");
+ });
+
+ flushNonBlockingError = t.step_func(function (error) {
+ assert_unreached("flushNonBlocking() error callback invoked: name:" + error.name + "msg:" + error.message);
+ });
+
+ fileHandleWrite = tizen.filesystem.openFile("documents/file", "w");
+
+ conversionTable = getTypeConversionExceptions("functionObject", true);
+ for (i = 0; i < conversionTable.length; i++) {
+ flushNonBlockingSuccess = conversionTable[i][0];
+
+ assert_throws({name: exceptionName}, function () {
+ fileHandleWrite.flushNonBlocking(flushNonBlockingSuccess, flushNonBlockingError);
+ }, exceptionName + " should be thrown - given incorrect successCallback.");
+ }
+ t.done();
+});
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileHandle_flushNonBlocking_successCallback_invalid_cb</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileHandle_flushNonBlocking_successCallback_invalid_cb
+//==== LABEL Check if FileHandle::flushNonBlocking() method throws exception when successCallback is invalid
+//==== SPEC Tizen Web API:IO:Filesystem:FileHandle:flushNonBlocking M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P2
+//==== ONLOAD_DELAY 90
+//==== TEST_CRITERIA MTCB
+
+var t = async_test(document.title), fileHandleWrite, invalidCallback, flushNonBlockingError;
+
+t.step(function () {
+ add_result_callback(function () {
+ fileHandleWrite.close();
+ tizen.filesystem.deleteFile("documents/file");
+ });
+
+ invalidCallback = {
+ onsuccess: t.step_func(function () {
+ assert_unreached("Invalid callback invoked");
+ })
+ };
+
+ flushNonBlockingError = t.step_func(function (error) {
+ assert_unreached("flushNonBlocking() error callback invoked: name:" + error.name + "msg:" + error.message);
+ });
+
+ fileHandleWrite = tizen.filesystem.openFile("documents/file", "w");
+ assert_throws(TYPE_MISMATCH_EXCEPTION, function () {
+ fileHandleWrite.flushNonBlocking(invalidCallback, flushNonBlockingError);
+ }, "given incorrect successCallback");
+ t.done();
+});
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileHandle_flushNonBlocking_with_onerror</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileHandle_flushNonBlocking_with_onerror
+//==== LABEL Check if FileHandle::flushNonBlocking() method works properly with onerror
+//==== SPEC Tizen Web API:IO:Filesystem:FileHandle:flushNonBlocking M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P1
+//==== ONLOAD_DELAY 90
+//==== TEST_CRITERIA MOA MR MAST
+
+var t = async_test(document.title), writeStringNonBlockingSuccess, writeStringNonBlockingError,
+ readStringNonBlockingSuccess, readStringNonBlockingError, fileHandleWrite, fileHandleRead, retVal,
+ flushNonBlockingSuccess, flushNonBlockingError, content = "Lorem ipsum dolor sit amet...";
+
+t.step(function () {
+ add_result_callback(function () {
+ try {
+ fileHandleWrite.close();
+ fileHandleRead.close();
+ tizen.filesystem.deleteFile("documents/file");
+ } catch (err) {
+ }
+ });
+
+ writeStringNonBlockingSuccess = t.step_func(function (bytesCount) {
+ });
+
+ writeStringNonBlockingError = t.step_func(function (error) {
+ assert_unreached("writeStringNonBlocking() error callback invoked: name:" + error.name + "msg:" + error.message);
+ });
+
+ flushNonBlockingSuccess = t.step_func(function () {
+ });
+
+ flushNonBlockingError = t.step_func(function (error) {
+ assert_unreached("flushNonBlocking() error callback invoked: name:" + error.name + "msg:" + error.message);
+ });
+
+ readStringNonBlockingSuccess = t.step_func(function (output) {
+ assert_equals(output, content, "the flush content is not right");
+ t.done();
+ });
+
+ readStringNonBlockingError = t.step_func(function (error) {
+ assert_unreached("readStringNonBlocking() error callback invoked: name:" + error.name + "msg:" + error.message);
+ });
+
+ fileHandleWrite = tizen.filesystem.openFile("documents/file", "w");
+ fileHandleWrite.writeStringNonBlocking(content, writeStringNonBlockingSuccess, writeStringNonBlockingError);
+ retVal = fileHandleWrite.flushNonBlocking(flushNonBlockingSuccess, flushNonBlockingError);
+ assert_equals(retVal, undefined, "return value should be undefined");
+
+ fileHandleRead = tizen.filesystem.openFile("documents/file", "r");
+ fileHandleRead.readStringNonBlocking(readStringNonBlockingSuccess, readStringNonBlockingError);
+});
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileHandle_flush_exist</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileHandle_flush_exist
+//==== LABEL Check if FileHandle::flush() method exists
+//==== SPEC Tizen Web API:IO:Filesystem:FileHandle:flush M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P0
+//==== TEST_CRITERIA ME
+
+test(function () {
+ var fileHandleWrite;
+
+ add_result_callback(function () {
+ fileHandleWrite.close();
+ tizen.filesystem.deleteFile("documents/file");
+ });
+
+ fileHandleWrite = tizen.filesystem.openFile("documents/file", "w");
+ check_method_exists(fileHandleWrite, "flush");
+}, document.title);
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileHandle_flush_extra_argument</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileHandle_flush_extra_argument
+//==== LABEL Check using FileHandle::flush() method with extra argument
+//==== SPEC Tizen Web API:IO:Filesystem:FileHandle:flush M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P1
+//==== TEST_CRITERIA MNAEX
+
+test(function () {
+ var fileHandleWrite;
+
+ add_result_callback(function () {
+ fileHandleWrite.close();
+ tizen.filesystem.deleteFile("documents/file");
+ });
+
+ fileHandleWrite = tizen.filesystem.openFile("documents/file", "w");
+ checkExtraArgument(fileHandleWrite, "flush");
+}, document.title);
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileHandle_notexist</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileHandle_notexist
+//==== LABEL Interface FileHandle should not be accessible
+//==== SPEC Tizen Web API:IO:Filesystem:FileHandle:FileHandle U
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P3
+//==== TEST_CRITERIA NIO
+
+test(function () {
+ check_no_interface_object("FileHandle");
+}, document.title);
+
+</script>
+</body>
+</html>
\ No newline at end of file
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileHandle_path_attribute</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileHandle_path_attribute
+//==== LABEL Check if FileHandle::path attribute exists, has type DOMString and is readonly
+//==== SPEC Tizen Web API:IO:Filesystem:FileHandle:path A
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P1
+//==== TEST_CRITERIA AE AT ARO
+
+test(function () {
+ var fileHandleWrite;
+
+ add_result_callback(function () {
+ try {
+ fileHandleWrite.close();
+ tizen.filesystem.deleteFile("documents/file");
+ } catch (err) {
+ }
+ });
+
+ fileHandleWrite = tizen.filesystem.openFile("documents/file", "w");
+ check_readonly(fileHandleWrite, "path", "documents/file", "string", "test/file");
+}, document.title);
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileHandle_readBlob</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileHandle_readBlob
+//==== LABEL Check if FileHandle::readBlob() method works properly
+//==== SPEC Tizen Web API:IO:Filesystem:FileHandle:readBlob M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P1
+//==== TEST_CRITERIA MR MMINA
+
+test(function () {
+ var fileHandleWrite, blob, fileHandleRead, fileContentsInBlob, content = "Lorem ipsum dolor sit amet...";
+
+ add_result_callback(function () {
+ try {
+ tizen.filesystem.deleteFile("documents/file");
+ } catch (err) {
+ }
+ });
+
+ blob = new Blob([content], {type: "text/plain"});
+ fileHandleWrite = tizen.filesystem.openFile("documents/file", "w");
+ fileHandleWrite.writeBlob(blob);
+ fileHandleWrite.close();
+
+ fileHandleRead = tizen.filesystem.openFile("documents/file", "r");
+ fileContentsInBlob = fileHandleRead.readBlob();
+ assert_type(fileContentsInBlob, "object", "The type returned should be of object type.");
+ assert_true(fileContentsInBlob instanceof Blob, "return value should be instance of Blob object");
+ fileHandleRead.close();
+}, document.title);
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileHandle_readBlobNonBlocking</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileHandle_readBlobNonBlocking
+//==== LABEL Check if FileHandle::readBlobNonBlocking() method works properly
+//==== SPEC Tizen Web API:IO:Filesystem:FileHandle:readBlobNonBlocking M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P1
+//==== ONLOAD_DELAY 90
+//==== TEST_CRITERIA MR MMINA
+
+var t = async_test(document.title), writeBlobNonBlockingSuccess, writeBlobNonBlockingError,
+ fileHandleWrite, fileHandleRead, retVal, blob, content = "Lorem ipsum dolor sit amet...";
+
+t.step(function () {
+ add_result_callback(function () {
+ try {
+ tizen.filesystem.deleteFile("documents/file");
+ } catch (err) {
+ }
+ });
+
+ writeBlobNonBlockingSuccess = t.step_func(function (blob) {
+ });
+
+ writeBlobNonBlockingError = t.step_func(function (error) {
+ assert_unreached("writeBlobNonBlocking() error callback invoked: name:" + error.name + "msg:" + error.message);
+ });
+
+ blob = new Blob([content], {type: "text/plain"});
+ fileHandleWrite = tizen.filesystem.openFile("documents/file", "w");
+ fileHandleWrite.writeBlobNonBlocking(blob, writeBlobNonBlockingSuccess, writeBlobNonBlockingError);
+ fileHandleWrite.close();
+
+ fileHandleRead = tizen.filesystem.openFile("documents/file", "r");
+ retVal = fileHandleRead.readBlobNonBlocking();
+ assert_equals(retVal, undefined, "return value should be undefined");
+ fileHandleRead.close();
+ t.done();
+});
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileHandle_readBlobNonBlocking_InvalidValuesError</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileHandle_readBlobNonBlocking_InvalidValuesError
+//==== LABEL Check if FileHandle::readBlobNonBlocking() method with invalid count throws InvalidValuesError
+//==== SPEC Tizen Web API:IO:Filesystem:FileHandle:readBlobNonBlocking M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P2
+//==== ONLOAD_DELAY 90
+//==== TEST_CRITERIA MC
+
+var t = async_test(document.title), writeBlobNonBlockingSuccess, writeBlobNonBlockingError,
+ fileHandleWrite, fileHandleRead, blob, content = "Lorem ipsum dolor sit amet...",
+ readBlobNonBlockingSuccess, readBlobNonBlockingError;
+
+t.step(function () {
+ add_result_callback(function () {
+ try {
+ tizen.filesystem.deleteFile("documents/file");
+ } catch (err) {
+ }
+ });
+
+ writeBlobNonBlockingSuccess = t.step_func(function (blob) {
+ });
+
+ writeBlobNonBlockingError = t.step_func(function (error) {
+ assert_unreached("writeBlobNonBlocking() error callback invoked: name:" + error.name + "msg:" + error.message);
+ });
+
+ readBlobNonBlockingSuccess = t.step_func(function (output) {
+ });
+
+ readBlobNonBlockingError = t.step_func(function (error) {
+ assert_unreached("readBlobNonBlocking() error callback invoked: name:" + error.name + "msg:" + error.message);
+ });
+
+ blob = new Blob([content], {type: "text/plain"});
+ fileHandleWrite = tizen.filesystem.openFile("documents/file", "w");
+ fileHandleWrite.writeBlobNonBlocking(blob, writeBlobNonBlockingSuccess, writeBlobNonBlockingError);
+ fileHandleWrite.close();
+
+ fileHandleRead = tizen.filesystem.openFile("documents/file", "r");
+ assert_throws(INVALID_VALUES_EXCEPTION, function () {
+ fileHandleRead.readBlobNonBlocking(readBlobNonBlockingSuccess, readBlobNonBlockingError, 0x7fffffffffffffff);
+ }, "InvalidValuesError should be thrown - invalid count.");
+ fileHandleRead.close();
+ t.done();
+});
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileHandle_readBlobNonBlocking_errorCallback_invalid_cb</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileHandle_readBlobNonBlocking_errorCallback_invalid_cb
+//==== LABEL Check if FileHandle::readBlobNonBlocking() method throws exception when errorCallback is invalid
+//==== SPEC Tizen Web API:IO:Filesystem:FileHandle:readBlobNonBlocking M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P2
+//==== ONLOAD_DELAY 90
+//==== TEST_CRITERIA MTCB
+
+var t = async_test(document.title), fileHandle, readBlobNonBlockingSuccess, invalidCallback;
+
+t.step(function () {
+ add_result_callback(function () {
+ try {
+ fileHandle.close();
+ tizen.filesystem.deleteFile("documents/file");
+ } catch (err) {
+ }
+ });
+
+ readBlobNonBlockingSuccess = t.step_func(function (output) {
+ assert_unreached("Should not be invoked readBlobNonBlocking SuccessCallback");
+ });
+
+ invalidCallback = {
+ onerror: t.step_func(function () {
+ assert_unreached("Invalid callback invoked");
+ })
+ };
+
+ fileHandle = tizen.filesystem.openFile("documents/file", "w");
+ assert_throws(TYPE_MISMATCH_EXCEPTION, function () {
+ fileHandle.readBlobNonBlocking(readBlobNonBlockingSuccess, invalidCallback);
+ }, "given incorrect errorCallback");
+ t.done();
+});
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileHandle_readBlobNonBlocking_errorCallback_invoked_IOError</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileHandle_readBlobNonBlocking_errorCallback_invoked_IOError
+//==== LABEL Check if errorcallback of FileHandle::readBlobNonBlocking() method can be invoked if input/output error occurs
+//==== SPEC Tizen Web API:IO:Filesystem:FileHandle:readBlobNonBlocking M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P2
+//==== ONLOAD_DELAY 90
+//==== TEST_CRITERIA MERRCB
+
+var t = async_test(document.title), writeBlobNonBlockingSuccess, writeBlobNonBlockingError,
+ fileHandleWrite, fileHandleRead, blob, content = "Lorem ipsum dolor sit amet...",
+ readBlobNonBlockingSuccess, readBlobNonBlockingError;
+
+t.step(function () {
+ add_result_callback(function () {
+ try {
+ tizen.filesystem.deleteFile("documents/file");
+ } catch (err) {
+ }
+ });
+
+ writeBlobNonBlockingSuccess = t.step_func(function (blob) {
+ });
+
+ writeBlobNonBlockingError = t.step_func(function (error) {
+ assert_unreached("writeBlobNonBlocking() error callback invoked: name:" + error.name + "msg:" + error.message);
+ });
+
+ readBlobNonBlockingSuccess = t.step_func(function (output) {
+ assert_unreached("Should not be invoked readBlobNonBlocking SuccessCallback");
+ });
+
+ readBlobNonBlockingError = t.step_func(function (error) {
+ assert_equals(error.name, "IOError", "expect to throw an IOError exception");
+ t.done();
+ });
+
+ blob = new Blob([content], {type: "text/plain"});
+ fileHandleWrite = tizen.filesystem.openFile("documents/file", "w");
+ fileHandleWrite.writeBlobNonBlocking(blob, writeBlobNonBlockingSuccess, writeBlobNonBlockingError);
+ fileHandleWrite.close();
+
+ fileHandleRead = tizen.filesystem.openFile("documents/file", "r");
+ fileHandleRead.close();
+ fileHandleRead.readBlobNonBlocking(readBlobNonBlockingSuccess, readBlobNonBlockingError);
+});
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileHandle_readBlobNonBlocking_exist</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileHandle_readBlobNonBlocking_exist
+//==== LABEL Check if FileHandle::readBlobNonBlocking() method exists
+//==== SPEC Tizen Web API:IO:Filesystem:FileHandle:readBlobNonBlocking M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P0
+//==== TEST_CRITERIA ME
+
+test(function () {
+ var fileHandle;
+
+ add_result_callback(function () {
+ try {
+ fileHandle.close();
+ tizen.filesystem.deleteFile("documents/file");
+ } catch (err) {
+ }
+ });
+
+ fileHandle = tizen.filesystem.openFile("documents/file", "w");
+ check_method_exists(fileHandle, "readBlobNonBlocking");
+}, document.title);
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileHandle_readBlobNonBlocking_onerror_TypeMismatch</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileHandle_readBlobNonBlocking_onerror_TypeMismatch
+//==== LABEL Check if FileHandle::readBlobNonBlocking() method throws exception for wrong type of onerror
+//==== SPEC Tizen Web API:IO:Filesystem:FileHandle:readBlobNonBlocking M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P2
+//==== ONLOAD_DELAY 90
+//==== TEST_CRITERIA MC
+
+var t = async_test(document.title), fileHandle, readBlobNonBlockingSuccess, readBlobNonBlockingError,
+ i, conversionTable, exceptionName = "TypeMismatchError";
+
+t.step(function () {
+ add_result_callback(function () {
+ try {
+ fileHandle.close();
+ tizen.filesystem.deleteFile("documents/file");
+ } catch (err) {
+ }
+ });
+
+ readBlobNonBlockingSuccess = t.step_func(function (output) {
+ assert_unreached("Should not be invoked to readBlobNonBlocking SuccessCallback");
+ });
+
+ fileHandle = tizen.filesystem.openFile("documents/file", "w");
+
+ conversionTable = getTypeConversionExceptions("functionObject", true);
+ for (i = 0; i < conversionTable.length; i++) {
+ readBlobNonBlockingError = conversionTable[i][0];
+
+ assert_throws({name: exceptionName}, function () {
+ fileHandle.readBlobNonBlocking(readBlobNonBlockingSuccess, readBlobNonBlockingError);
+ }, exceptionName + " should be thrown - given incorrect errorCallback.");
+ }
+ t.done();
+});
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileHandle_readBlobNonBlocking_onsuccess_TypeMismatch</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileHandle_readBlobNonBlocking_onsuccess_TypeMismatch
+//==== LABEL Check if FileHandle::readBlobNonBlocking() method throws exception for wrong type of onsuccess
+//==== SPEC Tizen Web API:IO:Filesystem:FileHandle:readBlobNonBlocking M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P2
+//==== ONLOAD_DELAY 90
+//==== TEST_CRITERIA MC
+
+var t = async_test(document.title), fileHandle, readBlobNonBlockingSuccess, readBlobNonBlockingError,
+ i, conversionTable, exceptionName = "TypeMismatchError";
+
+t.step(function () {
+ add_result_callback(function () {
+ try {
+ fileHandle.close();
+ tizen.filesystem.deleteFile("documents/file");
+ } catch (err) {
+ }
+ });
+
+ readBlobNonBlockingError = t.step_func(function (error) {
+ assert_unreached("readBlobNonBlocking() error callback invoked: name:" + error.name + "msg:" + error.message);
+ });
+
+ fileHandle = tizen.filesystem.openFile("documents/file", "w");
+
+ conversionTable = getTypeConversionExceptions("functionObject", true);
+ for (i = 0; i < conversionTable.length; i++) {
+ readBlobNonBlockingSuccess = conversionTable[i][0];
+
+ assert_throws({name: exceptionName}, function () {
+ fileHandle.readBlobNonBlocking(readBlobNonBlockingSuccess, readBlobNonBlockingError);
+ }, exceptionName + " should be thrown - given incorrect successCallback.");
+ }
+ t.done();
+});
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileHandle_readBlobNonBlocking_successCallback_invalid_cb</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileHandle_readBlobNonBlocking_successCallback_invalid_cb
+//==== LABEL Check if FileHandle::readBlobNonBlocking() method throws exception when successCallback is invalid
+//==== SPEC Tizen Web API:IO:Filesystem:FileHandle:readBlobNonBlocking M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P2
+//==== ONLOAD_DELAY 90
+//==== TEST_CRITERIA MTCB
+
+var t = async_test(document.title), fileHandle, invalidCallback, readBlobNonBlockingError;
+
+t.step(function () {
+ add_result_callback(function () {
+ try {
+ fileHandle.close();
+ tizen.filesystem.deleteFile("documents/file");
+ } catch (err) {
+ }
+ });
+
+ invalidCallback = {
+ onsuccess: t.step_func(function (blob) {
+ assert_unreached("Invalid callback invoked");
+ })
+ };
+
+ readBlobNonBlockingError = t.step_func(function (error) {
+ assert_unreached("Should not be invoked readBlobNonBlockingErrorCallback");
+ });
+
+ fileHandle = tizen.filesystem.openFile("documents/file", "w");
+ assert_throws(TYPE_MISMATCH_EXCEPTION, function () {
+ fileHandle.readBlobNonBlocking(invalidCallback, readBlobNonBlockingError);
+ }, "given incorrect successCallback");
+ t.done();
+});
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileHandle_readBlobNonBlocking_with_size</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileHandle_readBlobNonBlocking_with_size
+//==== LABEL Check if FileHandle::readBlobNonBlocking() method works properly with inputEncoding
+//==== SPEC Tizen Web API:IO:Filesystem:FileHandle:readBlobNonBlocking M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P1
+//==== ONLOAD_DELAY 90
+//==== TEST_CRITERIA MOA MR
+
+var t = async_test(document.title), writeBlobNonBlockingSuccess, writeBlobNonBlockingError,
+ fileHandleWrite, fileHandleRead, retVal, blob, content = "Lorem ipsum dolor sit amet...",
+ readBlobNonBlockingSuccess, readBlobNonBlockingError, eventCallback, reader;
+
+t.step(function () {
+ add_result_callback(function () {
+ try {
+ tizen.filesystem.deleteFile("documents/file");
+ } catch (err) {
+ }
+ });
+
+ eventCallback = t.step_func(function (contents) {
+ text = contents.srcElement.result;
+ assert_equals(text, content.substring(0, 5), "The read blob content is not right");
+ fileHandleRead.close();
+ t.done();
+ });
+
+ writeBlobNonBlockingSuccess = t.step_func(function (blob) {
+ });
+
+ writeBlobNonBlockingError = t.step_func(function (error) {
+ assert_unreached("writeBlobNonBlocking() error callback invoked: name:" + error.name + "msg:" + error.message);
+ });
+
+ readBlobNonBlockingSuccess = t.step_func(function (outputBlob) {
+ assert_equals(retVal, undefined, "return value should be undefined");
+ reader.readAsText(outputBlob);
+ });
+
+ readBlobNonBlockingError = t.step_func(function (error) {
+ assert_unreached("readBlobNonBlocking() error callback invoked: name:" + error.name + "msg:" + error.message);
+ });
+
+ blob = new Blob([content], {type: "text/plain"});
+ fileHandleWrite = tizen.filesystem.openFile("documents/file", "w");
+ fileHandleWrite.writeBlobNonBlocking(blob, writeBlobNonBlockingSuccess, writeBlobNonBlockingError);
+ fileHandleWrite.close();
+
+ fileHandleRead = tizen.filesystem.openFile("documents/file", "r");
+ reader = new FileReader(),
+ reader.addEventListener("loadend", eventCallback);
+ retVal = fileHandleRead.readBlobNonBlocking(readBlobNonBlockingSuccess, readBlobNonBlockingError, 5);
+});
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileHandle_readBlob_IOError</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileHandle_readBlob_IOError
+//==== LABEL Check if FileHandle::readBlob() method with file handle closed throws IOError
+//==== SPEC Tizen Web API:IO:Filesystem:FileHandle:readBlob M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P2
+//==== TEST_CRITERIA MC
+
+test(function () {
+ var fileHandle;
+
+ add_result_callback(function () {
+ try {
+ tizen.filesystem.deleteFile("documents/file");
+ } catch (err) {
+ }
+ });
+
+ fileHandle = tizen.filesystem.openFile("documents/file", "w");
+ fileHandle.close();
+ assert_throws(IO_EXCEPTION, function () {
+ fileHandle.readBlob();
+ }, "IOError should be thrown - file handle closed.");
+}, document.title);
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileHandle_readBlob_InvalidValuesError</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileHandle_readBlob_InvalidValuesError
+//==== LABEL Check if FileHandle::readBlob() method with invalid count throws InvalidValuesError
+//==== SPEC Tizen Web API:IO:Filesystem:FileHandle:readBlob M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P2
+//==== TEST_CRITERIA MC
+
+test(function () {
+ var fileHandleWrite, blob, fileHandleRead, content = "Lorem ipsum dolor sit amet...";
+
+ add_result_callback(function () {
+ try {
+ tizen.filesystem.deleteFile("documents/file");
+ } catch (err) {
+ }
+ });
+
+ blob = new Blob([content], {type: "text/plain"});
+ fileHandleWrite = tizen.filesystem.openFile("documents/file", "w");
+ fileHandleWrite.writeBlob(blob);
+ fileHandleWrite.close();
+
+ fileHandleRead = tizen.filesystem.openFile("documents/file", "r");
+ assert_throws(INVALID_VALUES_EXCEPTION, function () {
+ fileHandleRead.readBlob(0x7fffffffffffffff);
+ }, "InvalidValuesError should be thrown - invalid count.");
+ fileHandleRead.close();
+}, document.title);
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileHandle_readBlob_exist</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileHandle_readBlob_exist
+//==== LABEL Check if FileHandle::readBlob() method exists
+//==== SPEC Tizen Web API:IO:Filesystem:FileHandle:readBlob M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P0
+//==== TEST_CRITERIA ME
+
+test(function () {
+ var fileHandle;
+
+ add_result_callback(function () {
+ try {
+ fileHandle.close();
+ tizen.filesystem.deleteFile("documents/file");
+ } catch (err) {
+ }
+ });
+
+ fileHandle = tizen.filesystem.openFile("documents/file", "w");
+ check_method_exists(fileHandle, "readBlob");
+}, document.title);
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileHandle_readBlob_with_size</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileHandle_readBlob_with_size
+//==== LABEL Check if FileHandle::readBlob() method works properly with size
+//==== SPEC Tizen Web API:IO:Filesystem:FileHandle:readBlob M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P1
+//==== TEST_CRITERIA MOA MR
+
+var t = async_test(document.title), fileHandleWrite, blob, fileHandleRead,
+ fileContentsInBlob, content = "Lorem ipsum dolor sit amet...", eventCallback, reader;
+
+t.step(function () {
+ add_result_callback(function () {
+ try {
+ tizen.filesystem.deleteFile("documents/file");
+ } catch (err) {
+ }
+ });
+
+ eventCallback = t.step_func(function (contents) {
+ text = contents.srcElement.result;
+ assert_equals(text, content.substring(0, 3), "The read blob content is not right");
+ t.done();
+ });
+
+ blob = new Blob([content], {type: "text/plain"});
+ fileHandleWrite = tizen.filesystem.openFile("documents/file", "w");
+ fileHandleWrite.writeBlob(blob);
+ fileHandleWrite.close();
+
+ fileHandleRead = tizen.filesystem.openFile("documents/file", "r");
+ fileContentsInBlob = fileHandleRead.readBlob(3);
+ fileHandleRead.close();
+
+ assert_true(fileContentsInBlob instanceof Blob, "return value should be of Blob");
+ reader = new FileReader();
+ reader.addEventListener("loadend", eventCallback);
+ reader.readAsText(fileContentsInBlob);
+});
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileHandle_readData</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileHandle_readData
+//==== LABEL Check if FileHandle::readData() method works properly
+//==== SPEC Tizen Web API:IO:Filesystem:FileHandle:readData M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P1
+//==== TEST_CRITERIA MR MMINA
+
+test(function () {
+ var dataToWrite = new Uint8Array([11, 21, 31, 71, 81, 91]), fileHandleWrite, fileHandleRead, fileContentsInUint8Array;
+
+ add_result_callback(function () {
+ try {
+ tizen.filesystem.deleteFile("documents/file");
+ } catch (err) {
+ }
+ });
+
+ fileHandleWrite = tizen.filesystem.openFile("documents/file", "w");
+ fileHandleWrite.writeData(dataToWrite);
+ fileHandleWrite.close();
+
+ fileHandleRead = tizen.filesystem.openFile("documents/file", "r");
+ fileContentsInUint8Array = fileHandleRead.readData();
+ assert_type(fileContentsInUint8Array, "object", "The type returned should be of object type.");
+ assert_array_equals(fileContentsInUint8Array, dataToWrite, "Data read from file is not right");
+ fileHandleRead.close();
+}, document.title);
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileHandle_readDataNonBlocking</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileHandle_readDataNonBlocking
+//==== LABEL Check if FileHandle::readDataNonBlocking() method works properly
+//==== SPEC Tizen Web API:IO:Filesystem:FileHandle:readDataNonBlocking M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P1
+//==== ONLOAD_DELAY 90
+//==== TEST_CRITERIA MR MMINA
+
+var t = async_test(document.title), dataToWrite = new Uint8Array([11, 21, 31, 71, 81, 91]), writeDataNonBlockingSuccess, writeDataNonBlockingError,
+ fileHandleWrite, retVal, fileHandleRead;
+
+t.step(function () {
+ add_result_callback(function () {
+ try {
+ tizen.filesystem.deleteFile("documents/file");
+ } catch (err) {
+ }
+ });
+
+ writeDataNonBlockingSuccess = t.step_func(function () {
+ });
+
+ writeDataNonBlockingError = t.step_func(function (error) {
+ assert_unreached("writeDataNonBlocking() error callback invoked: name:" + error.name + "msg:" + error.message);
+ });
+
+ fileHandleWrite = tizen.filesystem.openFile("documents/file", "w");
+ fileHandleWrite.writeDataNonBlocking(dataToWrite, writeDataNonBlockingSuccess, writeDataNonBlockingError);
+ fileHandleWrite.close();
+
+ fileHandleRead = tizen.filesystem.openFile("documents/file", "r");
+ retVal = fileHandleRead.readDataNonBlocking();
+ assert_equals(retVal, undefined, "return value should be undefined");
+
+ fileHandleRead.close();
+ t.done();
+});
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileHandle_readDataNonBlocking_InvalidValuesError</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileHandle_readDataNonBlocking_InvalidValuesError
+//==== LABEL Check if FileHandle::readDataNonBlocking() method with invalid size throws InvalidValuesError
+//==== SPEC Tizen Web API:IO:Filesystem:FileHandle:readDataNonBlocking M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P2
+//==== TEST_CRITERIA MC
+
+var t = async_test(document.title), dataToWrite = new Uint8Array([11, 21, 31, 71, 81, 91]), writeDataNonBlockingSuccess, writeDataNonBlockingError,
+ readDataNonBlockingSuccess, readDataNonBlockingError, fileHandleWrite, fileHandleRead;
+
+t.step(function () {
+ add_result_callback(function () {
+ try {
+ tizen.filesystem.deleteFile("documents/file");
+ } catch (err) {
+ }
+ });
+
+ writeDataNonBlockingSuccess = t.step_func(function (data) {
+ });
+
+ writeDataNonBlockingError = t.step_func(function (error) {
+ assert_unreached("writeDataNonBlocking() error callback invoked: name:" + error.name + "msg:" + error.message);
+ });
+
+ readDataNonBlockingSuccess = t.step_func(function (position) {
+ });
+
+ readDataNonBlockingError = t.step_func(function (error) {
+ assert_unreached("readDataNonBlocking() error callback invoked: name:" + error.name + "msg:" + error.message);
+ });
+
+ fileHandleWrite = tizen.filesystem.openFile("documents/file", "w");
+ fileHandleWrite.writeDataNonBlocking(dataToWrite, writeDataNonBlockingSuccess, writeDataNonBlockingError);
+ fileHandleWrite.close();
+
+ fileHandleRead = tizen.filesystem.openFile("documents/file", "r");
+ assert_throws(INVALID_VALUES_EXCEPTION, function () {
+ fileHandleRead.readDataNonBlocking(readDataNonBlockingSuccess, readDataNonBlockingError, 0x7fffffffffffffff);
+ }, "InvalidValuesError should be thrown - invalid size.");
+ fileHandleRead.close();
+ t.done();
+});
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileHandle_readDataNonBlocking_errorCallback_invalid_cb</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileHandle_readDataNonBlocking_errorCallback_invalid_cb
+//==== LABEL Check if FileHandle::readDataNonBlocking() method throws exception when errorCallback is invalid
+//==== SPEC Tizen Web API:IO:Filesystem:FileHandle:readDataNonBlocking M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P2
+//==== ONLOAD_DELAY 90
+//==== TEST_CRITERIA MTCB
+
+var t = async_test(document.title), readDataNonBlockingSuccess, invalidCallback, fileHandle;
+
+t.step(function () {
+ add_result_callback(function () {
+ try {
+ fileHandle.close();
+ tizen.filesystem.deleteFile("documents/file");
+ } catch (err) {
+ }
+ });
+
+ readDataNonBlockingSuccess = t.step_func(function (position) {
+ assert_unreached("Should not be invoked readDataNonBlocking SuccessCallback");
+ });
+
+ invalidCallback = {
+ onerror: t.step_func(function () {
+ assert_unreached("Invalid callback invoked");
+ })
+ };
+
+ fileHandle = tizen.filesystem.openFile("documents/file", "w");
+ assert_throws(TYPE_MISMATCH_EXCEPTION, function () {
+ fileHandle.readDataNonBlocking(readDataNonBlockingSuccess, invalidCallback);
+ }, "given incorrect errorCallback");
+ t.done();
+});
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileHandle_readDataNonBlocking_errorCallback_invoked</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileHandle_readDataNonBlocking_errorCallback_invoked
+//==== LABEL Check if errorcallback of FileHandle::readDataNonBlocking() method can be invoked with file handle occurs error
+//==== SPEC Tizen Web API:IO:Filesystem:FileHandle:readDataNonBlocking M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P2
+//==== ONLOAD_DELAY 90
+//==== TEST_CRITERIA MERRCB
+
+var t = async_test(document.title), dataToWrite = new Uint8Array([11, 21, 31, 71, 81, 91]), writeDataNonBlockingSuccess, writeDataNonBlockingError,
+ readDataNonBlockingSuccess, readDataNonBlockingError, fileHandleWrite, fileHandleRead;
+
+t.step(function () {
+ add_result_callback(function () {
+ try {
+ tizen.filesystem.deleteFile("documents/file");
+ } catch (err) {
+ }
+ });
+
+ writeDataNonBlockingSuccess = t.step_func(function (data) {
+ });
+
+ writeDataNonBlockingError = t.step_func(function (error) {
+ assert_unreached("writeDataNonBlocking() error callback invoked: name:" + error.name + "msg:" + error.message);
+ });
+
+ readDataNonBlockingSuccess = t.step_func(function (position) {
+ assert_unreached("Should not be invoked readDataNonBlocking SuccessCallback");
+ });
+
+ readDataNonBlockingError = t.step_func(function (error) {
+ assert_equals(error.name, "IOError", "expect to throw an IOError exception");
+ t.done();
+ });
+
+ fileHandleWrite = tizen.filesystem.openFile("documents/file", "w");
+ fileHandleWrite.writeDataNonBlocking(dataToWrite, writeDataNonBlockingSuccess, writeDataNonBlockingError);
+ fileHandleWrite.close();
+
+ fileHandleRead = tizen.filesystem.openFile("documents/file", "r");
+
+ fileHandleRead.close();
+ fileHandleRead.readDataNonBlocking(readDataNonBlockingSuccess, readDataNonBlockingError);
+});
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileHandle_readDataNonBlocking_exist</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileHandle_readDataNonBlocking_exist
+//==== LABEL Check if FileHandle::readDataNonBlocking() method exists
+//==== SPEC Tizen Web API:IO:Filesystem:FileHandle:readDataNonBlocking M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P0
+//==== TEST_CRITERIA ME
+
+test(function () {
+ var fileHandle;
+
+ add_result_callback(function () {
+ try {
+ fileHandle.close();
+ tizen.filesystem.deleteFile("documents/file");
+ } catch (err) {
+ }
+ });
+
+ fileHandle = tizen.filesystem.openFile("documents/file", "w");
+ check_method_exists(fileHandle, "readDataNonBlocking");
+}, document.title);
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileHandle_readDataNonBlocking_onerror_TypeMismatch</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileHandle_readDataNonBlocking_onerror_TypeMismatch
+//==== LABEL Check if FileHandle::readDataNonBlocking() method throws exception for wrong type of onerror
+//==== SPEC Tizen Web API:IO:Filesystem:FileHandle:readDataNonBlocking M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P2
+//==== TEST_CRITERIA MC
+
+var t = async_test(document.title), readDataNonBlockingSuccess, readDataNonBlockingError,
+ fileHandle, i, conversionTable, exceptionName = "TypeMismatchError";
+
+t.step(function () {
+ add_result_callback(function () {
+ try {
+ fileHandle.close();
+ tizen.filesystem.deleteFile("documents/file");
+ } catch (err) {
+ }
+ });
+
+ readDataNonBlockingSuccess = t.step_func(function (position) {
+ assert_unreached("Should not be invoked to readDataNonBlocking Successcallback");
+ });
+
+ fileHandle = tizen.filesystem.openFile("documents/file", "w");
+ conversionTable = getTypeConversionExceptions("functionObject", true);
+ for (i = 0; i < conversionTable.length; i++) {
+ readDataNonBlockingError = conversionTable[i][0];
+
+ assert_throws({name: exceptionName}, function () {
+ fileHandle.readDataNonBlocking(readDataNonBlockingSuccess, readDataNonBlockingError);
+ }, exceptionName + " should be thrown - given incorrect errorCallback.");
+ }
+ t.done();
+});
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileHandle_readDataNonBlocking_onsuccess_TypeMismatch</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileHandle_readDataNonBlocking_onsuccess_TypeMismatch
+//==== LABEL Check if FileHandle::readDataNonBlocking() method throws exception for wrong type of onsuccess
+//==== SPEC Tizen Web API:IO:Filesystem:FileHandle:readDataNonBlocking M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P2
+//==== TEST_CRITERIA MC
+
+var t = async_test(document.title), readDataNonBlockingSuccess, readDataNonBlockingError,
+ fileHandle, i, conversionTable, exceptionName = "TypeMismatchError";
+
+t.step(function () {
+ add_result_callback(function () {
+ try {
+ fileHandle.close();
+ tizen.filesystem.deleteFile("documents/file");
+ } catch (err) {
+ }
+ });
+
+ readDataNonBlockingError = t.step_func(function (error) {
+ assert_unreached("readDataNonBlocking() error callback invoked: name:" + error.name + "msg:" + error.message);
+ });
+
+ fileHandle = tizen.filesystem.openFile("documents/file", "w");
+ conversionTable = getTypeConversionExceptions("functionObject", true);
+ for (i = 0; i < conversionTable.length; i++) {
+ readDataNonBlockingSuccess = conversionTable[i][0];
+
+ assert_throws({name: exceptionName}, function () {
+ fileHandle.readDataNonBlocking(readDataNonBlockingSuccess, readDataNonBlockingError);
+ }, exceptionName + " should be thrown - given incorrect successCallback.");
+ }
+ t.done();
+});
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileHandle_readDataNonBlocking_successCallback_invalid_cb</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileHandle_readDataNonBlocking_successCallback_invalid_cb
+//==== LABEL Check if FileHandle::readDataNonBlocking() method throws exception when successCallback is invalid
+//==== SPEC Tizen Web API:IO:Filesystem:FileHandle:readDataNonBlocking M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P2
+//==== ONLOAD_DELAY 90
+//==== TEST_CRITERIA MTCB
+
+var t = async_test(document.title), readDataNonBlockingSuccess, readDataNonBlockingError, fileHandle;
+
+t.step(function () {
+ add_result_callback(function () {
+ try {
+ fileHandle.close();
+ tizen.filesystem.deleteFile("documents/file");
+ } catch (err) {
+ }
+ });
+
+ invalidCallback = {
+ onsuccess: t.step_func(function (position) {
+ assert_unreached("Invalid callback invoked");
+ })
+ };
+
+ readDataNonBlockingError = t.step_func(function (error) {
+ assert_unreached("readDataNonBlocking() error callback invoked: name:" + error.name + "msg:" + error.message);
+ });
+
+ fileHandle = tizen.filesystem.openFile("documents/file", "w");
+ assert_throws(TYPE_MISMATCH_EXCEPTION, function () {
+ fileHandle.readDataNonBlocking(invalidCallback, readDataNonBlockingError);
+ }, "given incorrect successCallback");
+ t.done();
+});
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileHandle_readDataNonBlocking_with_size</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileHandle_readDataNonBlocking_with_size
+//==== LABEL Check if FileHandle::readDataNonBlocking() method works properly with size
+//==== SPEC Tizen Web API:IO:Filesystem:FileHandle:readDataNonBlocking M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P1
+//==== ONLOAD_DELAY 90
+//==== TEST_CRITERIA MOA MR
+
+var t = async_test(document.title), dataToWrite = new Uint8Array([11, 21, 31, 71, 81, 91]), writeDataNonBlockingSuccess, writeDataNonBlockingError,
+ readDataNonBlockingSuccess, readDataNonBlockingError, fileHandleWrite, retVal, fileHandleRead;
+
+t.step(function () {
+ add_result_callback(function () {
+ try {
+ tizen.filesystem.deleteFile("documents/file");
+ } catch (err) {
+ }
+ });
+
+ writeDataNonBlockingSuccess = t.step_func(function () {
+ });
+
+ writeDataNonBlockingError = t.step_func(function (error) {
+ assert_unreached("writeDataNonBlocking() error callback invoked: name:" + error.name + "msg:" + error.message);
+ });
+
+ readDataNonBlockingSuccess = t.step_func(function (data) {
+ assert_equals(retVal, undefined, "return value should be undefined");
+ assert_array_equals(data, dataToWrite.subarray(0, 3), "Data read from file is not right");
+
+ fileHandleRead.close();
+ t.done();
+ });
+
+ readDataNonBlockingError = t.step_func(function (error) {
+ assert_unreached("readDataNonBlocking() error callback invoked: name:" + error.name + "msg:" + error.message);
+ });
+
+ fileHandleWrite = tizen.filesystem.openFile("documents/file", "w");
+ fileHandleWrite.writeDataNonBlocking(dataToWrite, writeDataNonBlockingSuccess, writeDataNonBlockingError);
+ fileHandleWrite.close();
+
+ fileHandleRead = tizen.filesystem.openFile("documents/file", "r");
+ retVal = fileHandleRead.readDataNonBlocking(readDataNonBlockingSuccess, readDataNonBlockingError, 3);
+});
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileHandle_readData_IOError</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileHandle_readData_IOError
+//==== LABEL Check if FileHandle::readData() method with file handle closed throws IOError
+//==== SPEC Tizen Web API:IO:Filesystem:FileHandle:readData M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P2
+//==== TEST_CRITERIA MC
+
+test(function () {
+ var dataToWrite = new Uint8Array([11, 21, 31, 71, 81, 91]), fileHandleWrite, fileHandleRead;
+
+ add_result_callback(function () {
+ try {
+ tizen.filesystem.deleteFile("documents/file");
+ } catch (err) {
+ }
+ });
+
+ fileHandleWrite = tizen.filesystem.openFile("documents/file", "w");
+ fileHandleWrite.writeData(dataToWrite);
+ fileHandleWrite.close();
+
+ fileHandleRead = tizen.filesystem.openFile("documents/file", "r");
+ fileHandleRead.close();
+ assert_throws(IO_EXCEPTION, function () {
+ fileHandleRead.readData();
+ }, "IOError should be thrown - file handle closed.");
+}, document.title);
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileHandle_readData_InvalidValuesError</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileHandle_readData_InvalidValuesError
+//==== LABEL Check if FileHandle::readData() method with invalid size throws InvalidValuesError
+//==== SPEC Tizen Web API:IO:Filesystem:FileHandle:readData M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P2
+//==== TEST_CRITERIA MC
+
+test(function () {
+ var dataToWrite = new Uint8Array([11, 21, 31, 71, 81, 91]), fileHandleWrite, fileHandleRead;
+
+ add_result_callback(function () {
+ try {
+ tizen.filesystem.deleteFile("documents/file");
+ } catch (err) {
+ }
+ });
+
+ fileHandleWrite = tizen.filesystem.openFile("documents/file", "w");
+ fileHandleWrite.writeData(dataToWrite);
+ fileHandleWrite.close();
+
+ fileHandleRead = tizen.filesystem.openFile("documents/file", "r");
+ assert_throws(INVALID_VALUES_EXCEPTION, function () {
+ fileHandleRead.readData(0x7fffffffffffffff);
+ }, "InvalidValuesError should be thrown - invalid count.");
+ fileHandleRead.close();
+}, document.title);
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileHandle_readData_exist</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileHandle_readData_exist
+//==== LABEL Check if FileHandle::readData() method exists
+//==== SPEC Tizen Web API:IO:Filesystem:FileHandle:readData M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P0
+//==== TEST_CRITERIA ME
+
+test(function () {
+ var fileHandle;
+
+ add_result_callback(function () {
+ try {
+ fileHandle.close();
+ tizen.filesystem.deleteFile("documents/file");
+ } catch (err) {
+ }
+ });
+
+ fileHandle = tizen.filesystem.openFile("documents/file", "w");
+ check_method_exists(fileHandle, "readData");
+}, document.title);
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileHandle_readData_with_size</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileHandle_readData_with_size
+//==== LABEL Check if FileHandle::readData() method works properly with size
+//==== SPEC Tizen Web API:IO:Filesystem:FileHandle:readData M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P1
+//==== TEST_CRITERIA MOA MR
+
+test(function () {
+ var dataToWrite = new Uint8Array([11, 21, 31, 71, 81, 91]), fileHandleWrite, fileHandleRead, fileContentsInUint8Array;
+
+ add_result_callback(function () {
+ try {
+ tizen.filesystem.deleteFile("documents/file");
+ } catch (err) {
+ }
+ });
+
+ fileHandleWrite = tizen.filesystem.openFile("documents/file", "w");
+ fileHandleWrite.writeData(dataToWrite);
+ fileHandleWrite.close();
+
+ fileHandleRead = tizen.filesystem.openFile("documents/file", "r");
+ fileContentsInUint8Array = fileHandleRead.readData(2);
+ assert_type(fileContentsInUint8Array, "object", "The type returned should be of object type.");
+ assert_array_equals(fileContentsInUint8Array, dataToWrite.subarray(0, 2), "Data read from file is not right");
+ fileHandleRead.close();
+}, document.title);
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileHandle_readString</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileHandle_readString
+//==== LABEL Check if FileHandle::readString() method works properly
+//==== SPEC Tizen Web API:IO:Filesystem:FileHandle:readString M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P1
+//==== TEST_CRITERIA MR MMINA
+
+test(function () {
+ var fileHandleWrite, fileHandleRead, fileContents, content = "Lorem ipsum dolor sit amet...";
+
+ add_result_callback(function () {
+ try {
+ tizen.filesystem.deleteFile("documents/file");
+ } catch (err) {
+ }
+ });
+
+ fileHandleWrite = tizen.filesystem.openFile("documents/file", "w");
+ fileHandleWrite.writeString(content);
+ fileHandleWrite.close();
+
+ fileHandleRead = tizen.filesystem.openFile("documents/file", "r");
+ fileContents = fileHandleRead.readString();
+ assert_type(fileContents, "string", "The type returned should be of string type.");
+ assert_equals(fileContents, content, "the read content should be same as the written content.");
+ fileHandleRead.close();
+}, document.title);
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileHandle_readStringNonBlocking</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileHandle_readStringNonBlocking
+//==== LABEL Check if FileHandle::readStringNonBlocking() method works properly
+//==== SPEC Tizen Web API:IO:Filesystem:FileHandle:readStringNonBlocking M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P1
+//==== ONLOAD_DELAY 90
+//==== TEST_CRITERIA MR MMINA
+
+var t = async_test(document.title), writeStringNonBlockingSuccess, writeStringNonBlockingError,
+ fileHandleWrite, fileHandleRead, retVal;
+
+t.step(function () {
+ add_result_callback(function () {
+ try {
+ tizen.filesystem.deleteFile("documents/file");
+ } catch (err) {
+ }
+ });
+
+ writeStringNonBlockingSuccess = t.step_func(function (bytesCount) {
+ });
+
+ writeStringNonBlockingError = t.step_func(function (error) {
+ assert_unreached("writeStringNonBlocking() error callback invoked: name:" + error.name + "msg:" + error.message);
+ });
+
+ fileHandleWrite = tizen.filesystem.openFile("documents/file", "w");
+ fileHandleWrite.writeStringNonBlocking("Lorem ipsum dolor sit amet...", writeStringNonBlockingSuccess, writeStringNonBlockingError);
+ fileHandleWrite.close();
+
+ fileHandleRead = tizen.filesystem.openFile("documents/file", "r");
+ retVal = fileHandleRead.readStringNonBlocking();
+ assert_equals(retVal, undefined, "return value should be undefined");
+ fileHandleRead.close();
+ t.done();
+});
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileHandle_readStringNonBlocking_InvalidValuesError</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileHandle_readStringNonBlocking_InvalidValuesError
+//==== LABEL Check if FileHandle::readStringNonBlocking() method with invalid count throws InvalidValuesError
+//==== SPEC Tizen Web API:IO:Filesystem:FileHandle:readStringNonBlocking M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P2
+//==== ONLOAD_DELAY 90
+//==== TEST_CRITERIA MC
+
+var t = async_test(document.title), readStringNonBlockingSuccess, readStringNonBlockingError, fileHandle;
+
+t.step(function () {
+ add_result_callback(function () {
+ try {
+ fileHandle.close();
+ tizen.filesystem.deleteFile("documents/file");
+ } catch (err) {
+ }
+ });
+
+ readStringNonBlockingSuccess = t.step_func(function (output) {
+ });
+
+ readStringNonBlockingError = t.step_func(function (error) {
+ assert_unreached("readStringNonBlocking() error callback invoked: name:" + error.name + "msg:" + error.message);
+ });
+
+ fileHandle = tizen.filesystem.openFile("documents/file", "w");
+ fileHandle.close();
+ fileHandle = tizen.filesystem.openFile("documents/file", "r");
+ assert_throws(INVALID_VALUES_EXCEPTION, function () {
+ fileHandle.readStringNonBlocking(readStringNonBlockingSuccess, readStringNonBlockingError, 0x7fffffffffffffff);
+ }, "InvalidValuesError should be thrown - invalid count.");
+ t.done();
+});
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileHandle_readStringNonBlocking_NotSupportedError</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileHandle_readStringNonBlocking_NotSupportedError
+//==== LABEL Check if readStringNonBlocking() method with not-supported encoding throws NotSupportedError
+//==== SPEC Tizen Web API:IO:Filesystem:FileHandle:readStringNonBlocking M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P2
+//==== ONLOAD_DELAY 90
+//==== TEST_CRITERIA MC
+
+var t = async_test(document.title), writeStringNonBlockingSuccess, writeStringNonBlockingError,
+ readStringNonBlockingSuccess, readStringNonBlockingError, fileHandleWrite, fileHandleRead;
+
+t.step(function () {
+ add_result_callback(function () {
+ try {
+ tizen.filesystem.deleteFile("documents/file");
+ } catch (err) {
+ }
+ });
+
+ writeStringNonBlockingSuccess = t.step_func(function (bytesCount) {
+ });
+
+ writeStringNonBlockingError = t.step_func(function (error) {
+ assert_unreached("writeStringNonBlocking() error callback invoked: name:" + error.name + "msg:" + error.message);
+ });
+
+ readStringNonBlockingSuccess = t.step_func(function (output) {
+ });
+
+ readStringNonBlockingError = t.step_func(function (error) {
+ assert_unreached("readStringNonBlocking() error callback invoked: name:" + error.name + "msg:" + error.message);
+ });
+
+ fileHandleWrite = tizen.filesystem.openFile("documents/file", "w");
+ fileHandleWrite.writeStringNonBlocking("Lorem ipsum dolor sit amet...", writeStringNonBlockingSuccess, writeStringNonBlockingError);
+ fileHandleWrite.close();
+
+ fileHandleRead = tizen.filesystem.openFile("documents/file", "r");
+ assert_throws(NOT_SUPPORTED_EXCEPTION, function () {
+ fileHandleRead.readStringNonBlocking(readStringNonBlockingSuccess, readStringNonBlockingError, 5, "wrong-encoding");
+ }, "NotSupportedError should be thrown - invalid encoding.");
+
+ fileHandleRead.close();
+ t.done();
+});
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileHandle_readStringNonBlocking_errorCallback_invalid_cb</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileHandle_readStringNonBlocking_errorCallback_invalid_cb
+//==== LABEL Check if FileHandle::readStringNonBlocking() method throws exception when errorCallback is invalid
+//==== SPEC Tizen Web API:IO:Filesystem:FileHandle:readStringNonBlocking M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P2
+//==== ONLOAD_DELAY 90
+//==== TEST_CRITERIA MTCB
+
+var t = async_test(document.title), readStringNonBlockingSuccess, invalidCallback, fileHandle;
+
+t.step(function () {
+ add_result_callback(function () {
+ try {
+ fileHandle.close();
+ tizen.filesystem.deleteFile("documents/file");
+ } catch (err) {
+ }
+ });
+
+ readStringNonBlockingSuccess = t.step_func(function (output) {
+ assert_unreached("Should not be invoked readStringNonBlocking SuccessCallback");
+ });
+
+ invalidCallback = {
+ onerror: t.step_func(function () {
+ assert_unreached("Invalid callback invoked");
+ })
+ };
+
+ fileHandle = tizen.filesystem.openFile("documents/file", "w");
+ assert_throws(TYPE_MISMATCH_EXCEPTION, function () {
+ fileHandle.readStringNonBlocking(readStringNonBlockingSuccess, invalidCallback);
+ }, "given incorrect errorCallback");
+ t.done();
+});
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileHandle_readStringNonBlocking_errorCallback_invoked_IOError</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileHandle_readStringNonBlocking_errorCallback_invoked_IOError
+//==== LABEL Check if errorcallback of FileHandle::readStringNonBlocking() method can be invoked if input/output error occurs
+//==== SPEC Tizen Web API:IO:Filesystem:FileHandle:readStringNonBlocking M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P2
+//==== ONLOAD_DELAY 90
+//==== TEST_CRITERIA MERRCB
+
+var t = async_test(document.title), writeStringNonBlockingSuccess, writeStringNonBlockingError,
+ readStringNonBlockingSuccess, readStringNonBlockingError, fileHandleWrite, fileHandleRead;
+
+t.step(function () {
+ add_result_callback(function () {
+ try {
+ tizen.filesystem.deleteFile("documents/file");
+ } catch (err) {
+ }
+ });
+
+ writeStringNonBlockingSuccess = t.step_func(function (bytesCount) {
+ });
+
+ writeStringNonBlockingError = t.step_func(function (error) {
+ assert_unreached("writeStringNonBlocking() error callback invoked: name:" + error.name + "msg:" + error.message);
+ });
+
+ readStringNonBlockingSuccess = t.step_func(function (output) {
+ assert_unreached("Should not be invoked readStringNonBlocking SuccessCallback");
+ });
+
+ readStringNonBlockingError = t.step_func(function (error) {
+ assert_equals(error.name, "IOError", "expect to throw an IOError exception");
+ t.done();
+ });
+
+ fileHandleWrite = tizen.filesystem.openFile("documents/file", "w");
+ fileHandleWrite.writeStringNonBlocking("Lorem ipsum dolor sit amet...", writeStringNonBlockingSuccess, writeStringNonBlockingError);
+ fileHandleWrite.close();
+
+ fileHandleRead = tizen.filesystem.openFile("documents/file", "r");
+ fileHandleRead.close();
+ fileHandleRead.readStringNonBlocking(readStringNonBlockingSuccess, readStringNonBlockingError);
+});
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileHandle_readStringNonBlocking_exist</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileHandle_readStringNonBlocking_exist
+//==== LABEL Check if FileHandle::readStringNonBlocking() method exists
+//==== SPEC Tizen Web API:IO:Filesystem:FileHandle:readStringNonBlocking M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P0
+//==== TEST_CRITERIA ME
+
+test(function () {
+ var fileHandle;
+
+ add_result_callback(function () {
+ try {
+ fileHandle.close();
+ tizen.filesystem.deleteFile("documents/file");
+ } catch (err) {
+ }
+ });
+
+ fileHandle = tizen.filesystem.openFile("documents/file", "w");
+ check_method_exists(fileHandle, "readStringNonBlocking");
+}, document.title);
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileHandle_readStringNonBlocking_onerror_TypeMismatch</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileHandle_readStringNonBlocking_onerror_TypeMismatch
+//==== LABEL Check if FileHandle::readStringNonBlocking() method throws exception for wrong type of onerror
+//==== SPEC Tizen Web API:IO:Filesystem:FileHandle:readStringNonBlocking M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P2
+//==== ONLOAD_DELAY 90
+//==== TEST_CRITERIA MC
+
+var t = async_test(document.title), readStringNonBlockingSuccess, readStringNonBlockingError,
+ fileHandle, i, conversionTable, exceptionName = "TypeMismatchError";
+
+t.step(function () {
+ add_result_callback(function () {
+ try {
+ fileHandle.close();
+ tizen.filesystem.deleteFile("documents/file");
+ } catch (err) {
+ }
+ });
+
+ readStringNonBlockingSuccess = t.step_func(function (output) {
+ assert_unreached("Should not be invoked to readStringNonBlocking SuccessCallback");
+ });
+
+ fileHandle = tizen.filesystem.openFile("documents/file", "w");
+
+ conversionTable = getTypeConversionExceptions("functionObject", true);
+ for (i = 0; i < conversionTable.length; i++) {
+ readStringNonBlockingError = conversionTable[i][0];
+
+ assert_throws({name: exceptionName}, function () {
+ fileHandle.readStringNonBlocking(readStringNonBlockingSuccess, readStringNonBlockingError);
+ }, exceptionName + " should be thrown - given incorrect errorCallback.");
+ }
+ t.done();
+});
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileHandle_readStringNonBlocking_onsuccess_TypeMismatch</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileHandle_readStringNonBlocking_onsuccess_TypeMismatch
+//==== LABEL Check if FileHandle::readStringNonBlocking() method throws exception for wrong type of onsuccess
+//==== SPEC Tizen Web API:IO:Filesystem:FileHandle:readStringNonBlocking M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P2
+//==== ONLOAD_DELAY 90
+//==== TEST_CRITERIA MC
+
+var t = async_test(document.title), readStringNonBlockingSuccess, readStringNonBlockingError,
+ fileHandle, i, conversionTable, exceptionName = "TypeMismatchError";
+
+t.step(function () {
+ add_result_callback(function () {
+ try {
+ fileHandle.close();
+ tizen.filesystem.deleteFile("documents/file");
+ } catch (err) {
+ }
+ });
+
+ readStringNonBlockingError = t.step_func(function (error) {
+ assert_unreached("Should be invoked to readStringNonBlockingErrorCallback");
+ });
+
+ fileHandle = tizen.filesystem.openFile("documents/file", "w");
+
+ conversionTable = getTypeConversionExceptions("functionObject", true);
+ for (i = 0; i < conversionTable.length; i++) {
+ readStringNonBlockingSuccess = conversionTable[i][0];
+
+ assert_throws({name: exceptionName}, function () {
+ fileHandle.readStringNonBlocking(readStringNonBlockingSuccess, readStringNonBlockingError);
+ }, exceptionName + " should be thrown - given incorrect successCallback.");
+ }
+ t.done();
+});
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileHandle_readStringNonBlocking_successCallback_invalid_cb</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileHandle_readStringNonBlocking_successCallback_invalid_cb
+//==== LABEL Check if FileHandle::readStringNonBlocking() method throws exception when successCallback is invalid
+//==== SPEC Tizen Web API:IO:Filesystem:FileHandle:readStringNonBlocking M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P2
+//==== ONLOAD_DELAY 90
+//==== TEST_CRITERIA MTCB
+
+var t = async_test(document.title), invalidCallback, readStringNonBlockingError, fileHandle;
+
+t.step(function () {
+ add_result_callback(function () {
+ try {
+ fileHandle.close();
+ tizen.filesystem.deleteFile("documents/file");
+ } catch (err) {
+ }
+ });
+
+ invalidCallback = {
+ onsuccess: t.step_func(function (output) {
+ assert_unreached("Invalid callback invoked");
+ })
+ };
+
+ readStringNonBlockingError = t.step_func(function (error) {
+ assert_unreached("readStringNonBlocking() error callback invoked: name:" + error.name + "msg:" + error.message);
+ });
+
+ fileHandle = tizen.filesystem.openFile("documents/file", "w");
+ assert_throws(TYPE_MISMATCH_EXCEPTION, function () {
+ fileHandle.readStringNonBlocking(invalidCallback, readStringNonBlockingError);
+ }, "given incorrect successCallback");
+ t.done();
+});
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileHandle_readStringNonBlocking_with_inputEncoding</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileHandle_readStringNonBlocking_with_inputEncoding
+//==== LABEL Check if FileHandle::readStringNonBlocking() method works properly with inputEncoding
+//==== SPEC Tizen Web API:IO:Filesystem:FileHandle:readStringNonBlocking M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P1
+//==== ONLOAD_DELAY 90
+//==== TEST_CRITERIA MOA MR
+
+var t = async_test(document.title), writeStringNonBlockingSuccess, writeStringNonBlockingError,
+ readStringNonBlockingSuccess, readStringNonBlockingError, fileHandleWrite, fileHandleRead, retVal,
+ content = "Lorem ipsum dolor sit amet...";
+
+t.step(function () {
+ add_result_callback(function () {
+ try {
+ tizen.filesystem.deleteFile("documents/file");
+ } catch (err) {
+ }
+ });
+
+ writeStringNonBlockingSuccess = t.step_func(function (bytesCount) {
+ });
+
+ writeStringNonBlockingError = t.step_func(function (error) {
+ assert_unreached("writeStringNonBlocking() error callback invoked: name:" + error.name + "msg:" + error.message);
+ });
+
+ readStringNonBlockingSuccess = t.step_func(function (output) {
+ assert_equals(retVal, undefined, "return value should be undefined");
+ assert_equals(output, content.substring(0, 5), "Data read from file is not right.");
+ fileHandleRead.close();
+ t.done();
+ });
+
+ readStringNonBlockingError = t.step_func(function (error) {
+ assert_unreached("readStringNonBlocking() error callback invoked: name:" + error.name + "msg:" + error.message);
+ });
+
+ fileHandleWrite = tizen.filesystem.openFile("documents/file", "w");
+ fileHandleWrite.writeStringNonBlocking(content, writeStringNonBlockingSuccess, writeStringNonBlockingError);
+ fileHandleWrite.close();
+
+ fileHandleRead = tizen.filesystem.openFile("documents/file", "r");
+ retVal = fileHandleRead.readStringNonBlocking(readStringNonBlockingSuccess, readStringNonBlockingError, 5, "UTF-8");
+});
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileHandle_readString_IOError</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileHandle_readString_IOError
+//==== LABEL Check if FileHandle::readString() method with file handle closed throws IOError
+//==== SPEC Tizen Web API:IO:Filesystem:FileHandle:readString M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P2
+//==== TEST_CRITERIA MC
+
+test(function () {
+ var fileHandleWrite, fileHandleRead, fileContents, content = "Lorem ipsum dolor sit amet...";
+
+ add_result_callback(function () {
+ try {
+ tizen.filesystem.deleteFile("documents/file");
+ } catch (err) {
+ }
+ });
+
+ fileHandleWrite = tizen.filesystem.openFile("documents/file", "w");
+ fileHandleWrite.writeString(content);
+ fileHandleWrite.close();
+
+ fileHandleRead = tizen.filesystem.openFile("documents/file", "r");
+ fileHandleRead.close();
+ assert_throws(IO_EXCEPTION, function () {
+ fileHandleRead.readString(content);
+ }, "IOError should be thrown - file handle closed.");
+}, document.title);
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileHandle_readString_InvalidValuesError</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileHandle_readString_InvalidValuesError
+//==== LABEL Check if FileHandle::readString() method with invalid count throws InvalidValuesError
+//==== SPEC Tizen Web API:IO:Filesystem:FileHandle:readString M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P2
+//==== TEST_CRITERIA MC
+
+test(function () {
+ var fileHandleWrite, fileHandleRead, fileContents, content = "Lorem ipsum dolor sit amet...";
+
+ add_result_callback(function () {
+ try {
+ fileHandleRead.close();
+ tizen.filesystem.deleteFile("documents/file");
+ } catch (err) {
+ }
+ });
+
+ fileHandleWrite = tizen.filesystem.openFile("documents/file", "w");
+ fileHandleWrite.writeString(content);
+ fileHandleWrite.close();
+
+ fileHandleRead = tizen.filesystem.openFile("documents/file", "r");
+ assert_throws(INVALID_VALUES_EXCEPTION, function () {
+ fileHandleRead.readString(0x7fffffffffffffff);
+ }, "InvalidValuesError should be thrown - invalid count.");
+}, document.title);
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileHandle_readString_NotSupportedError</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileHandle_readString_NotSupportedError
+//==== LABEL Check if FileHandle::readString() method with invalid encoding throws NotSupportedError
+//==== SPEC Tizen Web API:IO:Filesystem:FileHandle:readString M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P2
+//==== TEST_CRITERIA MC
+
+test(function () {
+ var fileHandleWrite, fileHandleRead, fileContents, content = "Lorem ipsum dolor sit amet...";
+
+ add_result_callback(function () {
+ try {
+ fileHandleRead.close();
+ tizen.filesystem.deleteFile("documents/file");
+ } catch (err) {
+ }
+ });
+
+ fileHandleWrite = tizen.filesystem.openFile("documents/file", "w");
+ fileHandleWrite.writeString(content);
+ fileHandleWrite.close();
+
+ fileHandleRead = tizen.filesystem.openFile("documents/file", "r");
+ assert_throws(NOT_SUPPORTED_EXCEPTION, function () {
+ fileHandleRead.readString(5, "wrongencoding");
+ }, "NotSupportedError should be thrown - invalid encoding.");
+}, document.title);
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileHandle_readString_exist</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileHandle_readString_exist
+//==== LABEL Check if FileHandle::readString() method exists
+//==== SPEC Tizen Web API:IO:Filesystem:FileHandle:readString M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P0
+//==== TEST_CRITERIA ME
+
+test(function () {
+ var fileHandle;
+
+ add_result_callback(function () {
+ try {
+ fileHandle.close();
+ tizen.filesystem.deleteFile("documents/file");
+ } catch (err) {
+ }
+ });
+
+ fileHandle = tizen.filesystem.openFile("documents/file", "w");
+ check_method_exists(fileHandle, "readString");
+}, document.title);
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileHandle_readString_with_inputEncoding</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileHandle_readString_with_inputEncoding
+//==== LABEL Check if FileHandle::readString() method works properly with inputEncoding
+//==== SPEC Tizen Web API:IO:Filesystem:FileHandle:readString M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P1
+//==== TEST_CRITERIA MOA MR
+
+test(function () {
+ var fileHandleWrite, fileHandleRead, fileContents, content = "Lorem ipsum dolor sit amet...";
+
+ add_result_callback(function () {
+ try {
+ tizen.filesystem.deleteFile("documents/file");
+ } catch (err) {
+ }
+ });
+
+ fileHandleWrite = tizen.filesystem.openFile("documents/file", "w");
+ fileHandleWrite.writeString(content);
+ fileHandleWrite.close();
+
+ fileHandleRead = tizen.filesystem.openFile("documents/file", "r");
+ fileContents = fileHandleRead.readString(5, "UTF-8");
+ assert_type(fileContents, "string", "The type returned should be of string type.");
+ assert_equals(fileContents, content.substring(0, 5), "the read content should be same as the written content.");
+ fileHandleRead.close();
+}, document.title);
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileHandle_seek</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileHandle_seek
+//==== LABEL Check if FileHandle::seek() method works properly
+//==== SPEC Tizen Web API:IO:Filesystem:FileHandle:seek M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P1
+//==== TEST_CRITERIA MR MMINA
+
+test(function () {
+ var dataToWrite = new Uint8Array([11, 21, 31, 44, 55, 66, 71, 81, 91]), fileHandleWrite, fileHandleRead, position;
+
+ add_result_callback(function () {
+ try {
+ tizen.filesystem.deleteFile("documents/file");
+ } catch (err) {
+ }
+ });
+
+ fileHandleWrite = tizen.filesystem.openFile("documents/file", "w");
+ fileHandleWrite.writeData(dataToWrite);
+ fileHandleWrite.close();
+
+ fileHandleRead = tizen.filesystem.openFile("documents/file", "r");
+ position = fileHandleRead.seek(3);
+ assert_type(position, "long long", "The type returned should be of long long type.");
+ assert_equals(position, 3, "the file position indicator should be 3 after seek 3.");
+ fileHandleRead.close();
+}, document.title);
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileHandle_seekNonBlocking</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileHandle_seekNonBlocking
+//==== LABEL Check if FileHandle::seekNonBlocking() method works properly
+//==== SPEC Tizen Web API:IO:Filesystem:FileHandle:seekNonBlocking M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P1
+//==== ONLOAD_DELAY 90
+//==== TEST_CRITERIA MR MMINA
+
+var t = async_test(document.title), writeStringNonBlockingSuccess, writeStringNonBlockingError, fileHandleWrite, retVal;
+
+t.step(function () {
+ add_result_callback(function () {
+ try {
+ fileHandleWrite.close();
+ tizen.filesystem.deleteFile("documents/file");
+ } catch (err) {
+ }
+ });
+
+ writeStringNonBlockingSuccess = t.step_func(function (bytesCount) {
+ });
+
+ writeStringNonBlockingError = t.step_func(function (error) {
+ assert_unreached("writeStringNonBlocking() error callback invoked: name:" + error.name + "msg:" + error.message);
+ });
+
+ fileHandleWrite = tizen.filesystem.openFile("documents/file", "w");
+ fileHandleWrite.writeStringNonBlocking("Lorem ipsum dolor sit amet...", writeStringNonBlockingSuccess, writeStringNonBlockingError);
+ retVal = fileHandleWrite.seekNonBlocking(3);
+ assert_equals(retVal, undefined, "return value should be undefined");
+ t.done();
+});
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileHandle_seekNonBlocking_errorCallback_invalid_cb</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileHandle_seekNonBlocking_errorCallback_invalid_cb
+//==== LABEL Check if FileHandle::seekNonBlocking() method throws exception when errorCallback is invalid
+//==== SPEC Tizen Web API:IO:Filesystem:FileHandle:seekNonBlocking M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P2
+//==== ONLOAD_DELAY 90
+//==== TEST_CRITERIA MTCB
+
+var t = async_test(document.title), writeStringNonBlockingSuccess, writeStringNonBlockingError,
+ seekNonBlockingSuccess, invalidCallback, fileHandleWrite;
+
+t.step(function () {
+ add_result_callback(function () {
+ try {
+ fileHandleWrite.close();
+ tizen.filesystem.deleteFile("documents/file");
+ } catch (err) {
+ }
+ });
+
+ writeStringNonBlockingSuccess = t.step_func(function (bytesCount) {
+ });
+
+ writeStringNonBlockingError = t.step_func(function (error) {
+ assert_unreached("writeStringNonBlocking() error callback invoked: name:" + error.name + "msg:" + error.message);
+ });
+
+ seekNonBlockingSuccess = t.step_func(function (position) {
+ assert_unreached("Should not be invoked seekNonBlocking SuccessCallback");
+ });
+
+ invalidCallback = {
+ onerror: t.step_func(function () {
+ assert_unreached("Invalid callback invoked");
+ })
+ };
+
+ fileHandleWrite = tizen.filesystem.openFile("documents/file", "w");
+ fileHandleWrite.writeStringNonBlocking("Lorem ipsum dolor sit amet...", writeStringNonBlockingSuccess, writeStringNonBlockingError);
+ assert_throws(TYPE_MISMATCH_EXCEPTION, function () {
+ fileHandleWrite.seekNonBlocking(3, seekNonBlockingSuccess, invalidCallback);
+ }, "given incorrect errorCallback");
+ t.done();
+});
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileHandle_seekNonBlocking_errorCallback_invoked</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileHandle_seekNonBlocking_errorCallback_invoked
+//==== LABEL Check if errorcallback of FileHandle::seekNonBlocking() method can be invoked with file handle occurs error
+//==== SPEC Tizen Web API:IO:Filesystem:FileHandle:seekNonBlocking M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P2
+//==== ONLOAD_DELAY 90
+//==== TEST_CRITERIA MERRCB
+
+var t = async_test(document.title), seekNonBlockingSuccess, seekNonBlockingError, fileHandleWrite;
+
+t.step(function () {
+ add_result_callback(function () {
+ try {
+ tizen.filesystem.deleteFile("documents/file");
+ } catch (err) {
+ }
+ });
+
+ seekNonBlockingSuccess = t.step_func(function (position) {
+ assert_unreached("Should not be invoked seekNonBlocking SuccessCallback");
+ });
+
+ seekNonBlockingError = t.step_func(function (error) {
+ assert_equals(error.name, "IOError", "expect to throw an IOError exception");
+ t.done();
+ });
+
+ fileHandleWrite = tizen.filesystem.openFile("documents/file", "w");
+ fileHandleWrite.close();
+ fileHandleWrite.seekNonBlocking(3, seekNonBlockingSuccess, seekNonBlockingError);
+});
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileHandle_seekNonBlocking_exist</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileHandle_seekNonBlocking_exist
+//==== LABEL Check if FileHandle::seekNonBlocking() method exists
+//==== SPEC Tizen Web API:IO:Filesystem:FileHandle:seekNonBlocking M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P0
+//==== TEST_CRITERIA ME
+
+test(function () {
+ var fileHandleWrite;
+
+ add_result_callback(function () {
+ try {
+ fileHandleWrite.close();
+ tizen.filesystem.deleteFile("documents/file");
+ } catch (err) {
+ }
+ });
+
+ fileHandleWrite = tizen.filesystem.openFile("documents/file", "w");
+ check_method_exists(fileHandleWrite, "seekNonBlocking");
+}, document.title);
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileHandle_seekNonBlocking_onerror_TypeMismatch</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileHandle_seekNonBlocking_onerror_TypeMismatch
+//==== LABEL Check if FileHandle::seekNonBlocking() method throws exception for wrong type of onerror
+//==== SPEC Tizen Web API:IO:Filesystem:FileHandle:seekNonBlocking M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P2
+//==== TEST_CRITERIA MC
+
+var t = async_test(document.title), writeStringNonBlockingSuccess, writeStringNonBlockingError,
+ seekNonBlockingSuccess, seekNonBlockingError, fileHandleWrite, i, conversionTable, exceptionName = "TypeMismatchError";
+
+t.step(function () {
+ add_result_callback(function () {
+ try {
+ fileHandleWrite.close();
+ tizen.filesystem.deleteFile("documents/file");
+ } catch (err) {
+ }
+ });
+
+ writeStringNonBlockingSuccess = t.step_func(function (bytesCount) {
+ });
+
+ writeStringNonBlockingError = t.step_func(function (error) {
+ assert_unreached("writeStringNonBlocking() error callback invoked: name:" + error.name + "msg:" + error.message);
+ });
+
+ seekNonBlockingSuccess = t.step_func(function (position) {
+ assert_unreached("Should not be invoked to seekNonBlocking SuccessCallback");
+ });
+
+ fileHandleWrite = tizen.filesystem.openFile("documents/file", "w");
+ fileHandleWrite.writeStringNonBlocking("Lorem ipsum dolor sit amet...", writeStringNonBlockingSuccess, writeStringNonBlockingError);
+
+ conversionTable = getTypeConversionExceptions("functionObject", true);
+ for (i = 0; i < conversionTable.length; i++) {
+ seekNonBlockingError = conversionTable[i][0];
+
+ assert_throws({name: exceptionName}, function () {
+ fileHandleWrite.seekNonBlocking(3, seekNonBlockingSuccess, seekNonBlockingError);
+ }, exceptionName + " should be thrown - given incorrect errorCallback.");
+ }
+ t.done();
+});
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileHandle_seekNonBlocking_onsuccess_TypeMismatch</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileHandle_seekNonBlocking_onsuccess_TypeMismatch
+//==== LABEL Check if FileHandle::seekNonBlocking() method throws exception for wrong type of onsuccess
+//==== SPEC Tizen Web API:IO:Filesystem:FileHandle:seekNonBlocking M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P2
+//==== TEST_CRITERIA MC
+
+var t = async_test(document.title), writeStringNonBlockingSuccess, writeStringNonBlockingError,
+ seekNonBlockingSuccess, fileHandleWrite, i, conversionTable, exceptionName = "TypeMismatchError";
+
+t.step(function () {
+ add_result_callback(function () {
+ try {
+ fileHandleWrite.close();
+ tizen.filesystem.deleteFile("documents/file");
+ } catch (err) {
+ }
+ });
+
+ writeStringNonBlockingSuccess = t.step_func(function (bytesCount) {
+ });
+
+ writeStringNonBlockingError = t.step_func(function (error) {
+ assert_unreached("writeStringNonBlocking() error callback invoked: name:" + error.name + "msg:" + error.message);
+ });
+
+ fileHandleWrite = tizen.filesystem.openFile("documents/file", "w");
+ fileHandleWrite.writeStringNonBlocking("Lorem ipsum dolor sit amet...", writeStringNonBlockingSuccess, writeStringNonBlockingError);
+
+ conversionTable = getTypeConversionExceptions("functionObject", true);
+ for (i = 0; i < conversionTable.length; i++) {
+ seekNonBlockingSuccess = conversionTable[i][0];
+
+ assert_throws({name: exceptionName}, function () {
+ fileHandleWrite.seekNonBlocking(3, seekNonBlockingSuccess);
+ }, exceptionName + " should be thrown - given incorrect successCallback.");
+ }
+ t.done();
+});
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileHandle_seekNonBlocking_successCallback_invalid_cb</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileHandle_seekNonBlocking_successCallback_invalid_cb
+//==== LABEL Check if FileHandle::seekNonBlocking() method throws exception when successCallback is invalid
+//==== SPEC Tizen Web API:IO:Filesystem:FileHandle:seekNonBlocking M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P2
+//==== ONLOAD_DELAY 90
+//==== TEST_CRITERIA MTCB
+
+var t = async_test(document.title), writeStringNonBlockingSuccess, writeStringNonBlockingError,
+ invalidCallback, seekNonBlockingError, fileHandleWrite;
+
+t.step(function () {
+ add_result_callback(function () {
+ try {
+ fileHandleWrite.close();
+ tizen.filesystem.deleteFile("documents/file");
+ } catch (err) {
+ }
+ });
+
+ writeStringNonBlockingSuccess = t.step_func(function (bytesCount) {
+ });
+
+ writeStringNonBlockingError = t.step_func(function (error) {
+ assert_unreached("writeStringNonBlocking() error callback invoked: name:" + error.name + "msg:" + error.message);
+ });
+
+ invalidCallback = {
+ onsuccess: t.step_func(function (position) {
+ assert_unreached("Invalid callback invoked");
+ })
+ };
+
+ seekNonBlockingError = t.step_func(function (error) {
+ assert_unreached("seekNonBlocking() error callback invoked: name:" + error.name + "msg:" + error.message);
+ });
+
+ fileHandleWrite = tizen.filesystem.openFile("documents/file", "w");
+ fileHandleWrite.writeStringNonBlocking("Lorem ipsum dolor sit amet...", writeStringNonBlockingSuccess, writeStringNonBlockingError);
+ assert_throws(TYPE_MISMATCH_EXCEPTION, function () {
+ fileHandleWrite.seekNonBlocking(3, invalidCallback, seekNonBlockingError);
+ }, "given incorrect successCallback");
+ t.done();
+});
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileHandle_seekNonBlocking_with_whence</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileHandle_seekNonBlocking_with_whence
+//==== LABEL Check if FileHandle::seekNonBlocking() method works properly with BaseSeekPosition whence
+//==== SPEC Tizen Web API:IO:Filesystem:FileHandle:seekNonBlocking M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P1
+//==== ONLOAD_DELAY 90
+//==== TEST_CRITERIA MOA MR
+
+var t = async_test(document.title), writeStringNonBlockingSuccess, writeStringNonBlockingError,
+ seekNonBlockingSuccess, seekNonBlockingError, fileHandleWrite, retVal, content = "Lorem ipsum dolor sit amet...";
+
+t.step(function () {
+ add_result_callback(function () {
+ try {
+ fileHandleWrite.close();
+ tizen.filesystem.deleteFile("documents/file");
+ } catch (err) {
+ }
+ });
+
+ writeStringNonBlockingSuccess = t.step_func(function (bytesCount) {
+ });
+
+ writeStringNonBlockingError = t.step_func(function (error) {
+ assert_unreached("writeStringNonBlocking() error callback invoked: name:" + error.name + "msg:" + error.message);
+ });
+
+ seekNonBlockingSuccess = t.step_func(function (position) {
+ assert_equals(retVal, undefined, "return value should be undefined");
+ assert_equals(position, content.length - 3, "The position after shift is not correct.");
+ t.done();
+ });
+
+ seekNonBlockingError = t.step_func(function (error) {
+ assert_unreached("seekNonBlocking() error callback invoked: name:" + error.name + "msg:" + error.message);
+ });
+
+ fileHandleWrite = tizen.filesystem.openFile("documents/file", "w");
+ fileHandleWrite.writeStringNonBlocking(content, writeStringNonBlockingSuccess, writeStringNonBlockingError);
+ retVal = fileHandleWrite.seekNonBlocking(-3, seekNonBlockingSuccess, seekNonBlockingError, "END");
+});
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileHandle_seek_IOError</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileHandle_seek_IOError
+//==== LABEL Check if FileHandle::seek() method with file handle closed throws IOError
+//==== SPEC Tizen Web API:IO:Filesystem:FileHandle:seek M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P2
+//==== TEST_CRITERIA MC
+
+test(function () {
+ var dataToWrite = new Uint8Array([11, 21, 31, 44, 55, 66, 71, 81, 91]), fileHandleWrite, fileHandleRead;
+
+ add_result_callback(function () {
+ try {
+ tizen.filesystem.deleteFile("documents/file");
+ } catch (err) {
+ }
+ });
+
+ fileHandleWrite = tizen.filesystem.openFile("documents/file", "w");
+ fileHandleWrite.writeData(dataToWrite);
+ fileHandleWrite.close();
+
+ fileHandleRead = tizen.filesystem.openFile("documents/file", "r");
+ fileHandleRead.close();
+ assert_throws(IO_EXCEPTION, function () {
+ fileHandleRead.seek(-3, "END");
+ }, "IOError should be thrown - file handle closed.");
+}, document.title);
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileHandle_seek_exist</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileHandle_seek_exist
+//==== LABEL Check if FileHandle::seek() method exists
+//==== SPEC Tizen Web API:IO:Filesystem:FileHandle:seek M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P0
+//==== TEST_CRITERIA ME
+
+test(function () {
+ var fileHandle;
+
+ add_result_callback(function () {
+ try {
+ fileHandle.close();
+ tizen.filesystem.deleteFile("documents/file");
+ } catch (err) {
+ }
+ });
+
+ fileHandle = tizen.filesystem.openFile("documents/file", "w");
+ check_method_exists(fileHandle, "seek");
+}, document.title);
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileHandle_seek_with_whence</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileHandle_seek_with_whence
+//==== LABEL Check if FileHandle::seek() method works properly with BaseSeekPosition whence
+//==== SPEC Tizen Web API:IO:Filesystem:FileHandle:seek M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P1
+//==== TEST_CRITERIA MOA MR
+
+test(function () {
+ var dataToWrite = new Uint8Array([11, 21, 31, 44, 55, 66, 71, 81, 91]), fileHandleWrite, fileHandleRead, position;
+
+ add_result_callback(function () {
+ try {
+ tizen.filesystem.deleteFile("documents/file");
+ } catch (err) {
+ }
+ });
+
+ fileHandleWrite = tizen.filesystem.openFile("documents/file", "w");
+ fileHandleWrite.writeData(dataToWrite);
+ fileHandleWrite.close();
+
+ fileHandleRead = tizen.filesystem.openFile("documents/file", "r");
+ position = fileHandleRead.seek(-3, "END");
+ assert_type(position, "long long", "The type returned should be of long long type.");
+ assert_equals(position, 6, "the file position indicator should be 6 after seek -3 from end.");
+ fileHandleRead.close();
+}, document.title);
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileHandle_sync</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileHandle_sync
+//==== LABEL Check if FileHandle::sync() method works properly
+//==== SPEC Tizen Web API:IO:Filesystem:FileHandle:sync M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P1
+//==== TEST_CRITERIA MR MNA MNAST
+
+test(function () {
+ var dataToWrite = new Uint8Array([11, 21, 31, 71, 81, 91]), fileHandleWrite,
+ fileHandleRead, fileContentsInUint8Array, retVal;
+
+ add_result_callback(function () {
+ try {
+ fileHandleWrite.close();
+ fileHandleRead.close();
+ tizen.filesystem.deleteFile("documents/file");
+ } catch (err) {
+ }
+ });
+
+ fileHandleWrite = tizen.filesystem.openFile("documents/file", "w");
+ fileHandleWrite.writeData(dataToWrite);
+ retVal = fileHandleWrite.sync();
+ assert_equals(retVal, undefined, "return value should be undefined");
+
+ fileHandleRead = tizen.filesystem.openFile("documents/file", "r");
+ fileContentsInUint8Array = fileHandleRead.readData();
+ assert_array_equals(fileContentsInUint8Array, dataToWrite, "Data read from file is not right");
+}, document.title);
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileHandle_syncNonBlocking</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileHandle_syncNonBlocking
+//==== LABEL Check if FileHandle::syncNonBlocking() method works properly
+//==== SPEC Tizen Web API:IO:Filesystem:FileHandle:syncNonBlocking M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P1
+//==== ONLOAD_DELAY 90
+//==== TEST_CRITERIA MR MMINA MAST
+
+var t = async_test(document.title), dataToWrite = new Uint8Array([11, 21, 31, 71, 81, 91]), writeDataNonBlockingSuccess, writeDataNonBlockingError,
+ readDataNonBlockingSuccess, readDataNonBlockingError, fileHandleWrite, retVal, fileHandleRead;
+
+t.step(function () {
+ add_result_callback(function () {
+ try {
+ fileHandleWrite.close();
+ fileHandleRead.close();
+ tizen.filesystem.deleteFile("documents/file");
+ } catch (err) {
+ }
+ });
+
+ writeDataNonBlockingSuccess = t.step_func(function (data) {
+ });
+
+ writeDataNonBlockingError = t.step_func(function (error) {
+ assert_unreached("writeDataNonBlocking() error callback invoked: name:" + error.name + "msg:" + error.message);
+ });
+
+ readDataNonBlockingSuccess = t.step_func(function (data) {
+ assert_array_equals(data, dataToWrite, "Data read from file is not right");
+ t.done();
+ });
+
+ readDataNonBlockingError = t.step_func(function (error) {
+ assert_unreached("readDataNonBlocking() error callback invoked: name:" + error.name + "msg:" + error.message);
+ });
+
+ fileHandleWrite = tizen.filesystem.openFile("documents/file", "w");
+ fileHandleWrite.writeDataNonBlocking(dataToWrite, writeDataNonBlockingSuccess, writeDataNonBlockingError);
+ retVal = fileHandleWrite.syncNonBlocking();
+ assert_equals(retVal, undefined, "return value should be undefined");
+
+ fileHandleRead = tizen.filesystem.openFile("documents/file", "r");
+ fileHandleRead.readDataNonBlocking(readDataNonBlockingSuccess, readDataNonBlockingError);
+});
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileHandle_syncNonBlocking_errorCallback_invalid_cb</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileHandle_syncNonBlocking_errorCallback_invalid_cb
+//==== LABEL Check if FileHandle::syncNonBlocking() method throws exception when errorCallback is invalid
+//==== SPEC Tizen Web API:IO:Filesystem:FileHandle:syncNonBlocking M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P2
+//==== ONLOAD_DELAY 90
+//==== TEST_CRITERIA MTCB
+
+var t = async_test(document.title), dataToWrite = new Uint8Array([11, 21, 31, 71, 81, 91]),
+ writeDataNonBlockingSuccess, writeDataNonBlockingError, syncNonBlockingSuccess, invalidCallback, fileHandleWrite;
+
+t.step(function () {
+ add_result_callback(function () {
+ try {
+ fileHandleWrite.close();
+ tizen.filesystem.deleteFile("documents/file");
+ } catch (err) {
+ }
+ });
+
+ writeDataNonBlockingSuccess = t.step_func(function (data) {
+ });
+
+ writeDataNonBlockingError = t.step_func(function (error) {
+ assert_unreached("writeDataNonBlocking() error callback invoked: name:" + error.name + "msg:" + error.message);
+ });
+
+ syncNonBlockingSuccess = t.step_func(function () {
+ assert_unreached("Should not be invoked syncNonBlocking SuccessCallback");
+ });
+
+ invalidCallback = {
+ onerror: t.step_func(function () {
+ assert_unreached("Invalid callback invoked");
+ })
+ };
+
+ fileHandleWrite = tizen.filesystem.openFile("documents/file", "w");
+ fileHandleWrite.writeDataNonBlocking(dataToWrite, writeDataNonBlockingSuccess, writeDataNonBlockingError);
+ assert_throws(TYPE_MISMATCH_EXCEPTION, function () {
+ fileHandleWrite.syncNonBlocking(syncNonBlockingSuccess, invalidCallback);
+ }, "given incorrect errorCallback");
+ t.done();
+});
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileHandle_syncNonBlocking_errorCallback_invoked</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileHandle_syncNonBlocking_errorCallback_invoked
+//==== LABEL Check if errorcallback of FileHandle::syncNonBlocking() method can be invoked with file handle occurs error
+//==== SPEC Tizen Web API:IO:Filesystem:FileHandle:syncNonBlocking M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P2
+//==== ONLOAD_DELAY 90
+//==== TEST_CRITERIA MERRCB
+
+var t = async_test(document.title), dataToWrite = new Uint8Array([11, 21, 31, 71, 81, 91]),
+ writeDataNonBlockingSuccess, writeDataNonBlockingError, syncNonBlockingSuccess, syncNonBlockingError, fileHandleWrite;
+
+t.step(function () {
+ add_result_callback(function () {
+ try {
+ tizen.filesystem.deleteFile("documents/file");
+ } catch (err) {
+ }
+ });
+
+ writeDataNonBlockingSuccess = t.step_func(function (data) {
+ });
+
+ writeDataNonBlockingError = t.step_func(function (error) {
+ assert_unreached("writeDataNonBlocking() error callback invoked: name:" + error.name + "msg:" + error.message);
+ });
+
+ syncNonBlockingSuccess = t.step_func(function () {
+ assert_unreached("Should not be invoked syncNonBlocking SuccessCallback");
+ });
+
+ syncNonBlockingError = t.step_func(function (error) {
+ assert_equals(error.name, "IOError", "expect to throw an IOError exception");
+ t.done();
+ });
+
+ fileHandleWrite = tizen.filesystem.openFile("documents/file", "w");
+ fileHandleWrite.writeDataNonBlocking(dataToWrite, writeDataNonBlockingSuccess, writeDataNonBlockingError);
+ fileHandleWrite.close();
+ fileHandleWrite.syncNonBlocking(syncNonBlockingSuccess, syncNonBlockingError);
+});
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileHandle_syncNonBlocking_exist</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileHandle_syncNonBlocking_exist
+//==== LABEL Check if FileHandle::syncNonBlocking() method exists
+//==== SPEC Tizen Web API:IO:Filesystem:FileHandle:syncNonBlocking M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P0
+//==== TEST_CRITERIA ME
+
+test(function () {
+ var fileHandleWrite;
+
+ add_result_callback(function () {
+ try {
+ fileHandleWrite.close();
+ tizen.filesystem.deleteFile("documents/file");
+ } catch (err) {
+ }
+ });
+
+ fileHandleWrite = tizen.filesystem.openFile("documents/file", "w");
+ check_method_exists(fileHandleWrite, "syncNonBlocking");
+}, document.title);
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileHandle_syncNonBlocking_onerror_TypeMismatch</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileHandle_syncNonBlocking_onerror_TypeMismatch
+//==== LABEL Check if FileHandle::syncNonBlocking() method throws exception for wrong type of onerror
+//==== SPEC Tizen Web API:IO:Filesystem:FileHandle:syncNonBlocking M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P2
+//==== TEST_CRITERIA MC
+
+var t = async_test(document.title), dataToWrite = new Uint8Array([11, 21, 31, 71, 81, 91]),
+ writeDataNonBlockingSuccess, writeDataNonBlockingError, syncNonBlockingSuccess, syncNonBlockingError,
+ fileHandleWrite, i, conversionTable, exceptionName = "TypeMismatchError";
+
+t.step(function () {
+ add_result_callback(function () {
+ try {
+ fileHandleWrite.close();
+ tizen.filesystem.deleteFile("documents/file");
+ } catch (err) {
+ }
+ });
+
+ writeDataNonBlockingSuccess = t.step_func(function (data) {
+ });
+
+ writeDataNonBlockingError = t.step_func(function (error) {
+ assert_unreached("writeDataNonBlocking() error callback invoked: name:" + error.name + "msg:" + error.message);
+ });
+
+ syncNonBlockingSuccess = t.step_func(function () {
+ assert_unreached("Should not be invoked to syncNonBlocking Successcallback");
+ });
+
+ fileHandleWrite = tizen.filesystem.openFile("documents/file", "w");
+ fileHandleWrite.writeDataNonBlocking(dataToWrite, writeDataNonBlockingSuccess, writeDataNonBlockingError);
+ conversionTable = getTypeConversionExceptions("functionObject", true);
+ for (i = 0; i < conversionTable.length; i++) {
+ syncNonBlockingError = conversionTable[i][0];
+
+ assert_throws({name: exceptionName}, function () {
+ fileHandleWrite.syncNonBlocking(syncNonBlockingSuccess, syncNonBlockingError);
+ }, exceptionName + " should be thrown - given incorrect errorCallback.");
+ }
+ t.done();
+});
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileHandle_syncNonBlocking_onsuccess_TypeMismatch</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileHandle_syncNonBlocking_onsuccess_TypeMismatch
+//==== LABEL Check if FileHandle::syncNonBlocking() method throws exception for wrong type of onsuccess
+//==== SPEC Tizen Web API:IO:Filesystem:FileHandle:syncNonBlocking M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P2
+//==== TEST_CRITERIA MC
+
+var t = async_test(document.title), dataToWrite = new Uint8Array([11, 21, 31, 71, 81, 91]),
+ writeDataNonBlockingSuccess, writeDataNonBlockingError, syncNonBlockingSuccess, syncNonBlockingError,
+ fileHandleWrite, i, conversionTable, exceptionName = "TypeMismatchError";
+
+t.step(function () {
+ add_result_callback(function () {
+ try {
+ fileHandleWrite.close();
+ tizen.filesystem.deleteFile("documents/file");
+ } catch (err) {
+ }
+ });
+
+ writeDataNonBlockingSuccess = t.step_func(function (data) {
+ });
+
+ writeDataNonBlockingError = t.step_func(function (error) {
+ assert_unreached("writeDataNonBlocking() error callback invoked: name:" + error.name + "msg:" + error.message);
+ });
+
+ syncNonBlockingError = t.step_func(function (error) {
+ assert_unreached("syncNonBlocking() error callback invoked: name:" + error.name + "msg:" + error.message);
+ });
+
+ fileHandleWrite = tizen.filesystem.openFile("documents/file", "w");
+ fileHandleWrite.writeDataNonBlocking(dataToWrite, writeDataNonBlockingSuccess, writeDataNonBlockingError);
+ conversionTable = getTypeConversionExceptions("functionObject", true);
+ for (i = 0; i < conversionTable.length; i++) {
+ syncNonBlockingSuccess = conversionTable[i][0];
+
+ assert_throws({name: exceptionName}, function () {
+ fileHandleWrite.syncNonBlocking(syncNonBlockingSuccess, syncNonBlockingError);
+ }, exceptionName + " should be thrown - given incorrect successCallback.");
+ }
+ t.done();
+});
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileHandle_syncNonBlocking_successCallback_invalid_cb</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileHandle_syncNonBlocking_successCallback_invalid_cb
+//==== LABEL Check if FileHandle::syncNonBlocking() method throws exception when successCallback is invalid
+//==== SPEC Tizen Web API:IO:Filesystem:FileHandle:syncNonBlocking M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P2
+//==== ONLOAD_DELAY 90
+//==== TEST_CRITERIA MTCB
+
+var t = async_test(document.title), dataToWrite = new Uint8Array([11, 21, 31, 71, 81, 91]),
+ writeDataNonBlockingSuccess, writeDataNonBlockingError, invalidCallback, syncNonBlockingError, fileHandleWrite;
+
+t.step(function () {
+ add_result_callback(function () {
+ try {
+ fileHandleWrite.close();
+ tizen.filesystem.deleteFile("documents/file");
+ } catch (err) {
+ }
+ });
+
+ writeDataNonBlockingSuccess = t.step_func(function (data) {
+ });
+
+ writeDataNonBlockingError = t.step_func(function (error) {
+ assert_unreached("writeDataNonBlocking() error callback invoked: name:" + error.name + "msg:" + error.message);
+ });
+
+ invalidCallback = {
+ onsuccess: t.step_func(function () {
+ assert_unreached("Invalid callback invoked");
+ })
+ };
+
+ syncNonBlockingError = t.step_func(function (error) {
+ assert_unreached("syncNonBlocking() error callback invoked: name:" + error.name + "msg:" + error.message);
+ });
+
+ fileHandleWrite = tizen.filesystem.openFile("documents/file", "w");
+ fileHandleWrite.writeDataNonBlocking(dataToWrite, writeDataNonBlockingSuccess, writeDataNonBlockingError);
+ assert_throws(TYPE_MISMATCH_EXCEPTION, function () {
+ fileHandleWrite.syncNonBlocking(invalidCallback, syncNonBlockingError);
+ }, "given incorrect successCallback");
+ t.done();
+});
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileHandle_syncNonBlocking_with_onerror</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileHandle_syncNonBlocking_with_onerror
+//==== LABEL Check if FileHandle::syncNonBlocking() method works properly with onerror
+//==== SPEC Tizen Web API:IO:Filesystem:FileHandle:syncNonBlocking M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P1
+//==== ONLOAD_DELAY 90
+//==== TEST_CRITERIA MOA MR MAST
+
+var t = async_test(document.title), dataToWrite = new Uint8Array([11, 21, 31, 71, 81, 91]), writeDataNonBlockingSuccess, writeDataNonBlockingError,
+ readDataNonBlockingSuccess, readDataNonBlockingError, syncNonBlockingSuccess, syncNonBlockingError,
+ fileHandleWrite, retVal, fileHandleRead;
+
+t.step(function () {
+ add_result_callback(function () {
+ try {
+ fileHandleWrite.close();
+ fileHandleRead.close();
+ tizen.filesystem.deleteFile("documents/file");
+ } catch (err) {
+ }
+ });
+
+ writeDataNonBlockingSuccess = t.step_func(function (data) {
+ });
+
+ writeDataNonBlockingError = t.step_func(function (error) {
+ assert_unreached("writeDataNonBlocking() error callback invoked: name:" + error.name + "msg:" + error.message);
+ });
+
+ readDataNonBlockingSuccess = t.step_func(function (data) {
+ assert_array_equals(data, dataToWrite, "Data read from file is not right");
+ t.done();
+ });
+
+ readDataNonBlockingError = t.step_func(function (error) {
+ assert_unreached("readDataNonBlocking() error callback invoked: name:" + error.name + "msg:" + error.message);
+ });
+
+ syncNonBlockingSuccess = t.step_func(function () {
+ });
+
+ syncNonBlockingError = t.step_func(function (error) {
+ assert_unreached("syncNonBlocking() error callback invoked: name:" + error.name + "msg:" + error.message);
+ });
+
+ fileHandleWrite = tizen.filesystem.openFile("documents/file", "w");
+ fileHandleWrite.writeDataNonBlocking(dataToWrite, writeDataNonBlockingSuccess, writeDataNonBlockingError);
+ retVal = fileHandleWrite.syncNonBlocking(syncNonBlockingSuccess, syncNonBlockingError);
+ assert_equals(retVal, undefined, "return value should be undefined");
+
+ fileHandleRead = tizen.filesystem.openFile("documents/file", "r");
+ fileHandleRead.readDataNonBlocking(readDataNonBlockingSuccess, readDataNonBlockingError);
+});
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileHandle_sync_exist</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileHandle_sync_exist
+//==== LABEL Check if FileHandle::sync() method exists
+//==== SPEC Tizen Web API:IO:Filesystem:FileHandle:sync M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P0
+//==== TEST_CRITERIA ME
+
+test(function () {
+ var fileHandleWrite;
+
+ add_result_callback(function () {
+ try {
+ fileHandleWrite.close();
+ tizen.filesystem.deleteFile("documents/file");
+ } catch (err) {
+ }
+ });
+
+ fileHandleWrite = tizen.filesystem.openFile("documents/file", "w");
+ check_method_exists(fileHandleWrite, "sync");
+}, document.title);
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileHandle_sync_extra_argument</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileHandle_sync_extra_argument
+//==== LABEL Check using FileHandle::sync() method with extra argument
+//==== SPEC Tizen Web API:IO:Filesystem:FileHandle:sync M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P1
+//==== TEST_CRITERIA MNAEX
+
+test(function () {
+ var fileHandleWrite;
+
+ add_result_callback(function () {
+ try {
+ fileHandleWrite.close();
+ tizen.filesystem.deleteFile("documents/file");
+ } catch (err) {
+ }
+ });
+
+ fileHandleWrite = tizen.filesystem.openFile("documents/file", "w");
+ checkExtraArgument(fileHandleWrite, "sync");
+}, document.title);
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileHandle_writeBlob</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileHandle_writeBlob
+//==== LABEL Check if FileHandle::writeBlob() method works properly
+//==== SPEC Tizen Web API:IO:Filesystem:FileHandle:writeBlob M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P1
+//==== TEST_CRITERIA MR MAST
+
+var t = async_test(document.title), fileHandleWrite, blob, fileHandleRead, retVal, content = "Lorem ipsum dolor sit amet...",
+ reader = new FileReader(), fileContentsInBlob, eventCallback, text;
+
+t.step(function () {
+ add_result_callback(function () {
+ try {
+ tizen.filesystem.deleteFile("documents/file");
+ } catch (err) {
+ }
+ });
+
+ eventCallback = t.step_func(function (contents) {
+ text = contents.srcElement.result;
+ assert_equals(text, content, "The written blob content is not right.");
+ t.done();
+ });
+
+ blob = new Blob([content], {type: "text/plain"});
+ fileHandleWrite = tizen.filesystem.openFile("documents/file", "w");
+ retVal = fileHandleWrite.writeBlob(blob);
+ assert_equals(retVal, undefined, "return value should be undefined");
+ fileHandleWrite.close();
+
+ fileHandleRead = tizen.filesystem.openFile("documents/file", "r");
+ fileContentsInBlob = fileHandleRead.readBlob();
+ fileHandleRead.close();
+
+ reader.addEventListener("loadend", eventCallback);
+ reader.readAsText(fileContentsInBlob);
+});
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileHandle_writeBlobNonBlocking</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileHandle_writeBlobNonBlocking
+//==== LABEL Check if FileHandle::writeBlobNonBlocking() method works properly
+//==== SPEC Tizen Web API:IO:Filesystem:FileHandle:writeBlobNonBlocking M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P1
+//==== ONLOAD_DELAY 90
+//==== TEST_CRITERIA MR MMINA MAST
+
+var t = async_test(document.title), fileHandleWrite,
+ fileHandleRead, retVal, readBlobNonBlockingSuccess, readBlobNonBlockingError,
+ blob, content = "Lorem ipsum dolor sit amet...", reader, fileContentsInBlob, eventCallback, text;
+
+t.step(function () {
+ add_result_callback(function () {
+ try {
+ tizen.filesystem.deleteFile("documents/file");
+ } catch (err) {
+ }
+ });
+
+ eventCallback = t.step_func(function (contents) {
+ text = contents.srcElement.result;
+ assert_equals(text, content, "The written blob content is not right.");
+ t.done();
+ });
+
+ readBlobNonBlockingSuccess = t.step_func(function (fileContentsInBlob) {
+ reader.readAsText(fileContentsInBlob);
+ });
+
+ readBlobNonBlockingError = t.step_func(function (error) {
+ assert_unreached("readBlobNonBlocking() error callback invoked: name:" + error.name + "msg:" + error.message);
+ });
+
+ blob = new Blob([content], {type: "text/plain"});
+ fileHandleWrite = tizen.filesystem.openFile("documents/file", "w");
+ retVal = fileHandleWrite.writeBlobNonBlocking(blob);
+ assert_equals(retVal, undefined, "return value should be undefined");
+ fileHandleWrite.close();
+
+ fileHandleRead = tizen.filesystem.openFile("documents/file", "r");
+ reader = new FileReader(),
+ reader.addEventListener("loadend", eventCallback);
+ fileHandleRead.readBlobNonBlocking(readBlobNonBlockingSuccess, readBlobNonBlockingError);
+ fileHandleRead.close();
+});
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileHandle_writeBlobNonBlocking_blob_TypeMismatch</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileHandle_writeBlobNonBlocking_blob_TypeMismatch
+//==== LABEL Check if FileHandle:writeBlobNonBlocking() throws exception when blob is incorrect
+//==== SPEC Tizen Web API:IO:Filesystem:FileHandle:writeBlobNonBlocking M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P2
+//==== ONLOAD_DELAY 90
+//==== TEST_CRITERIA MC
+
+var t = async_test(document.title), fileHandleWrite, blob, i, conversionTable, exceptionName = "TypeMismatchError";
+
+t.step(function () {
+ add_result_callback(function () {
+ try {
+ fileHandleWrite.close();
+ tizen.filesystem.deleteFile("documents/file");
+ } catch (err) {
+ }
+ });
+
+ fileHandleWrite = tizen.filesystem.openFile("documents/file", "w");
+ conversionTable = getTypeConversionExceptions("object", false);
+ for (i = 0; i < conversionTable.length; i++) {
+ blob = conversionTable[i][0];
+
+ assert_throws({name: exceptionName}, function () {
+ fileHandleWrite.writeBlobNonBlocking(blob);
+ }, exceptionName + " should be thrown - given incorrect blob.");
+ }
+ t.done();
+});
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileHandle_writeBlobNonBlocking_errorCallback_invalid_cb</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileHandle_writeBlobNonBlocking_errorCallback_invalid_cb
+//==== LABEL Check if FileHandle::writeBlobNonBlocking() method throws exception when errorCallback is invalid
+//==== SPEC Tizen Web API:IO:Filesystem:FileHandle:writeBlobNonBlocking M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P2
+//==== ONLOAD_DELAY 90
+//==== TEST_CRITERIA MTCB
+
+var t = async_test(document.title), writeBlobNonBlockingSuccess, invalidCallback,
+ fileHandleWrite, blob, content = "Lorem ipsum dolor sit amet...";
+
+t.step(function () {
+ add_result_callback(function () {
+ try {
+ fileHandleWrite.close();
+ tizen.filesystem.deleteFile("documents/file");
+ } catch (err) {
+ }
+ });
+
+ writeBlobNonBlockingSuccess = t.step_func(function (blob) {
+ assert_unreached("Should not be invoked writeBlobNonBlocking SuccessCallback");
+ });
+
+ invalidCallback = {
+ onerror: t.step_func(function () {
+ assert_unreached("Invalid callback invoked");
+ })
+ };
+
+ blob = new Blob([content], {type: "text/plain"});
+ fileHandleWrite = tizen.filesystem.openFile("documents/file", "w");
+ assert_throws(TYPE_MISMATCH_EXCEPTION, function () {
+ fileHandleWrite.writeBlobNonBlocking(blob, writeBlobNonBlockingSuccess, invalidCallback);
+ }, "given incorrect errorCallback");
+ t.done();
+});
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileHandle_writeBlobNonBlocking_errorCallback_invoked_IOError</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileHandle_writeBlobNonBlocking_errorCallback_invoked_IOError
+//==== LABEL Check if errorcallback of FileHandle::writeBlobNonBlocking() method can be invoked if input/output error occurs
+//==== SPEC Tizen Web API:IO:Filesystem:FileHandle:writeBlobNonBlocking M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P2
+//==== ONLOAD_DELAY 90
+//==== TEST_CRITERIA MERRCB
+
+var t = async_test(document.title), writeBlobNonBlockingSuccess, writeBlobNonBlockingError,
+ fileHandleWrite, blob, content = "Lorem ipsum dolor sit amet...";
+
+t.step(function () {
+ add_result_callback(function () {
+ try {
+ tizen.filesystem.deleteFile("documents/file");
+ } catch (err) {
+ }
+ });
+
+ writeBlobNonBlockingSuccess = t.step_func(function (blob) {
+ assert_unreached("Should not be invoked writeBlobNonBlocking SuccessCallback");
+ });
+
+ writeBlobNonBlockingError = t.step_func(function (error) {
+ assert_equals(error.name, "IOError", "expect to throw an IOError exception");
+ t.done();
+ });
+
+ blob = new Blob([content], {type: "text/plain"});
+ fileHandleWrite = tizen.filesystem.openFile("documents/file", "w");
+ fileHandleWrite.close();
+ fileHandleWrite.writeBlobNonBlocking(blob, writeBlobNonBlockingSuccess, writeBlobNonBlockingError);
+});
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileHandle_writeBlobNonBlocking_exist</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileHandle_writeBlobNonBlocking_exist
+//==== LABEL Check if FileHandle::writeBlobNonBlocking() method exists
+//==== SPEC Tizen Web API:IO:Filesystem:FileHandle:writeBlobNonBlocking M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P0
+//==== TEST_CRITERIA ME
+
+test(function () {
+ var fileHandleWrite;
+
+ add_result_callback(function () {
+ try {
+ fileHandleWrite.close();
+ tizen.filesystem.deleteFile("documents/file");
+ } catch (err) {
+ }
+ });
+
+ fileHandleWrite = tizen.filesystem.openFile("documents/file", "w");
+ check_method_exists(fileHandleWrite, "writeBlobNonBlocking");
+}, document.title);
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileHandle_writeBlobNonBlocking_misarg</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileHandle_writeBlobNonBlocking_misarg
+//==== LABEL Check if FileHandle::writeBlobNonBlocking() method with missing mandatory argument throws exception
+//==== SPEC Tizen Web API:IO:Filesystem:FileHandle:writeBlobNonBlocking M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P2
+//==== TEST_CRITERIA MMA
+
+var t = async_test(document.title), fileHandleWrite;
+
+t.step(function () {
+ add_result_callback(function () {
+ try {
+ fileHandleWrite.close();
+ tizen.filesystem.deleteFile("documents/file");
+ } catch (err) {
+ }
+ });
+
+ fileHandleWrite = tizen.filesystem.openFile("documents/file", "w");
+ assert_throws(TYPE_MISMATCH_EXCEPTION, function () {
+ fileHandleWrite.writeBlobNonBlocking();
+ }, "TypeMismatchError should be thrown.");
+ t.done();
+});
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileHandle_writeBlobNonBlocking_onerror_TypeMismatch</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileHandle_writeBlobNonBlocking_onerror_TypeMismatch
+//==== LABEL Check if FileHandle::writeBlobNonBlocking() method throws exception for wrong type of onerror
+//==== SPEC Tizen Web API:IO:Filesystem:FileHandle:writeBlobNonBlocking M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P2
+//==== ONLOAD_DELAY 90
+//==== TEST_CRITERIA MC
+
+var t = async_test(document.title), writeBlobNonBlockingSuccess, writeBlobNonBlockingError,
+ fileHandleWrite, blob, content = "Lorem ipsum dolor sit amet...",
+ i, conversionTable, exceptionName = "TypeMismatchError";
+
+t.step(function () {
+ add_result_callback(function () {
+ try {
+ fileHandleWrite.close();
+ tizen.filesystem.deleteFile("documents/file");
+ } catch (err) {
+ }
+ });
+
+ writeBlobNonBlockingSuccess = t.step_func(function (blob) {
+ assert_unreached("Should not be invoked to writeBlobNonBlocking Successcallback");
+ });
+
+ blob = new Blob([content], {type: "text/plain"});
+ fileHandleWrite = tizen.filesystem.openFile("documents/file", "w");
+
+ conversionTable = getTypeConversionExceptions("functionObject", true);
+ for (i = 0; i < conversionTable.length; i++) {
+ writeBlobNonBlockingError = conversionTable[i][0];
+
+ assert_throws({name: exceptionName}, function () {
+ fileHandleWrite.writeBlobNonBlocking(blob, writeBlobNonBlockingSuccess, writeBlobNonBlockingError);
+ }, exceptionName + " should be thrown - given incorrect errorCallback.");
+ }
+ t.done();
+});
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileHandle_writeBlobNonBlocking_onsuccess_TypeMismatch</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileHandle_writeBlobNonBlocking_onsuccess_TypeMismatch
+//==== LABEL Check if FileHandle::writeBlobNonBlocking() method throws exception for wrong type of onsuccess
+//==== SPEC Tizen Web API:IO:Filesystem:FileHandle:writeBlobNonBlocking M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P2
+//==== ONLOAD_DELAY 90
+//==== TEST_CRITERIA MC
+
+var t = async_test(document.title), writeBlobNonBlockingSuccess, writeBlobNonBlockingError,
+ fileHandleWrite, blob, content = "Lorem ipsum dolor sit amet...",
+ i, conversionTable, exceptionName = "TypeMismatchError";
+
+t.step(function () {
+ add_result_callback(function () {
+ try {
+ fileHandleWrite.close();
+ tizen.filesystem.deleteFile("documents/file");
+ } catch (err) {
+ }
+ });
+
+ writeBlobNonBlockingError = t.step_func(function (error) {
+ assert_unreached("writeBlobNonBlocking() error callback invoked: name:" + error.name + "msg:" + error.message);
+ });
+
+ blob = new Blob([content], {type: "text/plain"});
+ fileHandleWrite = tizen.filesystem.openFile("documents/file", "w");
+
+ conversionTable = getTypeConversionExceptions("functionObject", true);
+ for (i = 0; i < conversionTable.length; i++) {
+ readBlobNonBlockingSuccess = conversionTable[i][0];
+
+ assert_throws({name: exceptionName}, function () {
+ fileHandleWrite.writeBlobNonBlocking(blob, writeBlobNonBlockingSuccess, writeBlobNonBlockingError);
+ }, exceptionName + " should be thrown - given incorrect successCallback.");
+ }
+ t.done();
+});
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileHandle_writeBlobNonBlocking_successCallback_invalid_cb</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileHandle_writeBlobNonBlocking_successCallback_invalid_cb
+//==== LABEL Check if FileHandle::writeBlobNonBlocking() method throws exception when successCallback is invalid
+//==== SPEC Tizen Web API:IO:Filesystem:FileHandle:writeBlobNonBlocking M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P2
+//==== ONLOAD_DELAY 90
+//==== TEST_CRITERIA MTCB
+
+var t = async_test(document.title), writeBlobNonBlockingSuccess, writeBlobNonBlockingError,
+ fileHandleWrite, blob, content = "Lorem ipsum dolor sit amet...";
+
+t.step(function () {
+ add_result_callback(function () {
+ try {
+ fileHandleWrite.close();
+ tizen.filesystem.deleteFile("documents/file");
+ } catch (err) {
+ }
+ });
+
+ invalidCallback = {
+ onsuccess: t.step_func(function (blob) {
+ assert_unreached("Invalid callback invoked");
+ })
+ };
+
+ writeBlobNonBlockingError = t.step_func(function (error) {
+ assert_unreached("writeBlobNonBlocking() error callback invoked: name:" + error.name + "msg:" + error.message);
+ });
+
+ blob = new Blob([content], {type: "text/plain"});
+ fileHandleWrite = tizen.filesystem.openFile("documents/file", "w");
+ assert_throws(TYPE_MISMATCH_EXCEPTION, function () {
+ fileHandleWrite.writeBlobNonBlocking(blob, invalidCallback, writeBlobNonBlockingError);
+ }, "given incorrect successCallback");
+ t.done();
+});
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileHandle_writeBlobNonBlocking_with_onerror</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileHandle_writeBlobNonBlocking_with_onerror
+//==== LABEL Check if FileHandle::writeBlobNonBlocking() method works properly with onerror
+//==== SPEC Tizen Web API:IO:Filesystem:FileHandle:writeBlobNonBlocking M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P1
+//==== ONLOAD_DELAY 90
+//==== TEST_CRITERIA MOA MR MAST
+
+var t = async_test(document.title), writeBlobNonBlockingSuccess, writeBlobNonBlockingError,
+ fileHandleWrite, fileHandleRead, retVal, readBlobNonBlockingSuccess, readBlobNonBlockingError,
+ blob, content = "Lorem ipsum dolor sit amet...", reader, fileContentsInBlob, eventCallback, text;
+
+t.step(function () {
+ add_result_callback(function () {
+ try {
+ fileHandleRead.close();
+ tizen.filesystem.deleteFile("documents/file");
+ } catch (err) {
+ }
+ });
+
+ eventCallback = t.step_func(function (contents) {
+ text = contents.srcElement.result;
+ assert_equals(text, content, "The written blob content is not right.");
+ t.done();
+ });
+
+ writeBlobNonBlockingSuccess = t.step_func(function (blob) {
+ });
+
+ writeBlobNonBlockingError = t.step_func(function (error) {
+ assert_unreached("writeBlobNonBlocking() error callback invoked: name:" + error.name + "msg:" + error.message);
+ });
+
+ readBlobNonBlockingSuccess = t.step_func(function (fileContentsInBlob) {
+ reader.readAsText(fileContentsInBlob);
+ });
+
+ readBlobNonBlockingError = t.step_func(function (error) {
+ assert_unreached("readBlobNonBlocking() error callback invoked: name:" + error.name + "msg:" + error.message);
+ });
+
+ blob = new Blob([content], {type: "text/plain"});
+ fileHandleWrite = tizen.filesystem.openFile("documents/file", "w");
+ retVal = fileHandleWrite.writeBlobNonBlocking(blob, writeBlobNonBlockingSuccess, writeBlobNonBlockingError);
+ assert_equals(retVal, undefined, "return value should be undefined");
+ fileHandleWrite.close();
+
+ fileHandleRead = tizen.filesystem.openFile("documents/file", "r");
+ reader = new FileReader(),
+ reader.addEventListener("loadend", eventCallback);
+ fileHandleRead.readBlobNonBlocking(readBlobNonBlockingSuccess, readBlobNonBlockingError);
+});
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileHandle_writeBlob_IOError</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileHandle_writeBlob_IOError
+//==== LABEL Check if FileHandle::writeBlob() method with file handle closed throws IOError
+//==== SPEC Tizen Web API:IO:Filesystem:FileHandle:writeBlob M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P2
+//==== TEST_CRITERIA MC
+
+test(function () {
+ var fileHandleWrite, blob, content = "Lorem ipsum dolor sit amet...";
+
+ add_result_callback(function () {
+ try {
+ tizen.filesystem.deleteFile("documents/file");
+ } catch (err) {
+ }
+ });
+
+ blob = new Blob([content], {type: "text/plain"});
+ fileHandleWrite = tizen.filesystem.openFile("documents/file", "w");
+ fileHandleWrite.close();
+ assert_throws(IO_EXCEPTION, function () {
+ fileHandleWrite.writeBlob(blob);
+ }, "IOError should be thrown - file handle closed.");
+}, document.title);
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileHandle_writeBlob_blob_TypeMismatch</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileHandle_writeBlob_blob_TypeMismatch
+//==== LABEL Check if FileHandle:writeBlob() throws exception when blob is incorrect
+//==== SPEC Tizen Web API:IO:Filesystem:FileHandle:writeBlob M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P2
+//==== TEST_CRITERIA MC
+
+test(function () {
+ var fileHandleWrite, blob, content = "Lorem ipsum dolor sit amet...",
+ i, conversionTable, exceptionName = "TypeMismatchError";
+
+ add_result_callback(function () {
+ try {
+ fileHandleWrite.close();
+ tizen.filesystem.deleteFile("documents/file");
+ } catch (err) {
+ }
+ });
+
+ fileHandleWrite = tizen.filesystem.openFile("documents/file", "w");
+
+ conversionTable = getTypeConversionExceptions("object", false);
+ for (i = 0; i < conversionTable.length; i++) {
+ blob = conversionTable[i][0];
+
+ assert_throws({name: exceptionName}, function () {
+ fileHandleWrite.writeBlob(blob);
+ }, exceptionName + " should be thrown - given incorrect blob.");
+ }
+}, document.title);
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileHandle_writeBlob_exist</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileHandle_writeBlob_exist
+//==== LABEL Check if FileHandle::writeBlob() method exists
+//==== SPEC Tizen Web API:IO:Filesystem:FileHandle:writeBlob M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P0
+//==== TEST_CRITERIA ME
+
+test(function () {
+ var fileHandleWrite;
+
+ add_result_callback(function () {
+ try {
+ fileHandleWrite.close();
+ tizen.filesystem.deleteFile("documents/file");
+ } catch (err) {
+ }
+ });
+
+ fileHandleWrite = tizen.filesystem.openFile("documents/file", "w");
+ check_method_exists(fileHandleWrite, "writeBlob");
+}, document.title);
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileHandle_writeBlob_misarg</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileHandle_writeBlob_misarg
+//==== LABEL Check if FileHandle::writeBlob() method with missing mandatory argument throws exception
+//==== SPEC Tizen Web API:IO:Filesystem:FileHandle:writeBlob M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P2
+//==== TEST_CRITERIA MMA
+
+test(function () {
+ var fileHandleWrite;
+
+ add_result_callback(function () {
+ try {
+ fileHandleWrite.close();
+ tizen.filesystem.deleteFile("documents/file");
+ } catch (err) {
+ }
+ });
+
+ fileHandleWrite = tizen.filesystem.openFile("documents/file", "w");
+ assert_throws(TYPE_MISMATCH_EXCEPTION, function () {
+ fileHandleWrite.writeBlob();
+ }, "TypeMismatchError should be thrown.");
+}, document.title);
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileHandle_writeData</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileHandle_writeData
+//==== LABEL Check if FileHandle::writeData() method works properly
+//==== SPEC Tizen Web API:IO:Filesystem:FileHandle:writeData M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P1
+//==== TEST_CRITERIA MR MAST
+
+test(function () {
+ var dataToWrite = new Uint8Array([11, 21, 31, 71, 81, 91]), fileHandleWrite, fileHandleRead, fileContentsInUint8Array, retVal;
+
+ add_result_callback(function () {
+ try {
+ tizen.filesystem.deleteFile("documents/file");
+ } catch (err) {
+ }
+ });
+
+ fileHandleWrite = tizen.filesystem.openFile("documents/file", "w");
+ retVal = fileHandleWrite.writeData(dataToWrite);
+ assert_equals(retVal, undefined, "return value should be undefined");
+ fileHandleWrite.close();
+
+ fileHandleRead = tizen.filesystem.openFile("documents/file", "r");
+ fileContentsInUint8Array = fileHandleRead.readData();
+ assert_array_equals(fileContentsInUint8Array, dataToWrite, "Data read from file is not right");
+ fileHandleRead.close();
+}, document.title);
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileHandle_writeDataNonBlocking</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileHandle_writeDataNonBlocking
+//==== LABEL Check if FileHandle::writeDataNonBlocking() method works properly
+//==== SPEC Tizen Web API:IO:Filesystem:FileHandle:writeDataNonBlocking M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P1
+//==== ONLOAD_DELAY 90
+//==== TEST_CRITERIA MR MMINA MAST
+
+var t = async_test(document.title), dataToWrite = new Uint8Array([11, 21, 31, 71, 81, 91]),
+ readDataNonBlockingSuccess, readDataNonBlockingError, fileHandleWrite, retVal, fileHandleRead;
+
+t.step(function () {
+ add_result_callback(function () {
+ try {
+ tizen.filesystem.deleteFile("documents/file");
+ } catch (err) {
+ }
+ });
+
+ readDataNonBlockingSuccess = t.step_func(function (data) {
+ assert_array_equals(data, dataToWrite, "Data read from file is not right");
+ fileHandleRead.close();
+ t.done();
+ });
+
+ readDataNonBlockingError = t.step_func(function (error) {
+ assert_unreached("readDataNonBlocking() error callback invoked: name:" + error.name + "msg:" + error.message);
+ });
+
+ fileHandleWrite = tizen.filesystem.openFile("documents/file", "w");
+ retVal = fileHandleWrite.writeDataNonBlocking(dataToWrite);
+ assert_equals(retVal, undefined, "return value should be undefined");
+ fileHandleWrite.close();
+
+ fileHandleRead = tizen.filesystem.openFile("documents/file", "r");
+ fileHandleRead.readDataNonBlocking(readDataNonBlockingSuccess, readDataNonBlockingError);
+});
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileHandle_writeDataNonBlocking_errorCallback_invalid_cb</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileHandle_writeDataNonBlocking_errorCallback_invalid_cb
+//==== LABEL Check if FileHandle::writeDataNonBlocking() method throws exception when errorCallback is invalid
+//==== SPEC Tizen Web API:IO:Filesystem:FileHandle:writeDataNonBlocking M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P2
+//==== ONLOAD_DELAY 90
+//==== TEST_CRITERIA MTCB
+
+var t = async_test(document.title), dataToWrite = new Uint8Array([11, 21, 31, 71, 81, 91]),
+ writeDataNonBlockingSuccess, invalidCallback, fileHandleWrite;
+
+t.step(function () {
+ add_result_callback(function () {
+ try {
+ fileHandleWrite.close();
+ tizen.filesystem.deleteFile("documents/file");
+ } catch (err) {
+ }
+ });
+
+ writeDataNonBlockingSuccess = t.step_func(function (data) {
+ assert_unreached("Should not be invoked writeDataNonBlocking SuccessCallback");
+ });
+
+ invalidCallback = {
+ onerror: t.step_func(function () {
+ assert_unreached("Invalid callback invoked");
+ })
+ };
+
+ fileHandleWrite = tizen.filesystem.openFile("documents/file", "w");
+ assert_throws(TYPE_MISMATCH_EXCEPTION, function () {
+ fileHandleWrite.writeDataNonBlocking(dataToWrite, writeDataNonBlockingSuccess, invalidCallback);
+ }, "given incorrect errorCallback");
+ t.done();
+});
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileHandle_writeDataNonBlocking_errorCallback_invoked</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileHandle_writeDataNonBlocking_errorCallback_invoked
+//==== LABEL Check if errorcallback of FileHandle::writeDataNonBlocking() method can be invoked with file handle occurs error
+//==== SPEC Tizen Web API:IO:Filesystem:FileHandle:writeDataNonBlocking M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P2
+//==== ONLOAD_DELAY 90
+//==== TEST_CRITERIA MERRCB
+
+var t = async_test(document.title), dataToWrite = new Uint8Array([11, 21, 31, 71, 81, 91]),
+ writeDataNonBlockingSuccess, writeDataNonBlockingError, fileHandleWrite;
+
+t.step(function () {
+ add_result_callback(function () {
+ try {
+ tizen.filesystem.deleteFile("documents/file");
+ } catch (err) {
+ }
+ });
+
+ writeDataNonBlockingSuccess = t.step_func(function (data) {
+ assert_unreached("Should not be invoked writeDataNonBlocking SuccessCallback");
+ });
+
+ writeDataNonBlockingError = t.step_func(function (error) {
+ assert_equals(error.name, "IOError", "expect to throw an IOError exception");
+ t.done();
+ });
+
+ fileHandleWrite = tizen.filesystem.openFile("documents/file", "w");
+ fileHandleWrite.close();
+ fileHandleWrite.writeDataNonBlocking(dataToWrite, writeDataNonBlockingSuccess, writeDataNonBlockingError);
+});
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileHandle_writeDataNonBlocking_exist</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileHandle_writeDataNonBlocking_exist
+//==== LABEL Check if FileHandle::writeDataNonBlocking() method exists
+//==== SPEC Tizen Web API:IO:Filesystem:FileHandle:writeDataNonBlocking M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== TEST_CRITERIA ME
+
+test(function () {
+ var fileHandleWrite;
+
+ add_result_callback(function () {
+ try {
+ fileHandleWrite.close();
+ tizen.filesystem.deleteFile("documents/file");
+ } catch (err) {
+ }
+ });
+
+ fileHandleWrite = tizen.filesystem.openFile("documents/file", "w");
+ check_method_exists(fileHandleWrite, "writeDataNonBlocking");
+}, document.title);
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileHandle_writeDataNonBlocking_misarg</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileHandle_writeDataNonBlocking_misarg
+//==== LABEL Check if FileHandle::writeDataNonBlocking() method with missing mandatory argument throws exception
+//==== SPEC Tizen Web API:IO:Filesystem:FileHandle:writeDataNonBlocking M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P2
+//==== TEST_CRITERIA MMA
+
+test(function () {
+ var fileHandleWrite;
+
+ add_result_callback(function () {
+ try {
+ fileHandleWrite.close();
+ tizen.filesystem.deleteFile("documents/file");
+ } catch (err) {
+ }
+ });
+
+ fileHandleWrite = tizen.filesystem.openFile("documents/file", "w");
+ assert_throws(TYPE_MISMATCH_EXCEPTION, function () {
+ fileHandleWrite.writeDataNonBlocking();
+ }, "TypeMismatchError should be thrown.");
+}, document.title);
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileHandle_writeDataNonBlocking_onerror_TypeMismatch</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileHandle_writeDataNonBlocking_onerror_TypeMismatch
+//==== LABEL Check if FileHandle::writeDataNonBlocking() method throws exception for wrong type of onerror
+//==== SPEC Tizen Web API:IO:Filesystem:FileHandle:writeDataNonBlocking M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P2
+//==== TEST_CRITERIA MC
+
+var t = async_test(document.title), dataToWrite = new Uint8Array([11, 21, 31, 71, 81, 91]), writeDataNonBlockingSuccess, writeDataNonBlockingError,
+ fileHandleWrite, i, conversionTable, exceptionName = "TypeMismatchError";
+
+t.step(function () {
+ add_result_callback(function () {
+ try {
+ fileHandleWrite.close();
+ tizen.filesystem.deleteFile("documents/file");
+ } catch (err) {
+ }
+ });
+
+ writeDataNonBlockingSuccess = t.step_func(function (data) {
+ assert_unreached("Should not be invoked to writeDataNonBlocking Successcallback");
+ });
+
+ writeDataNonBlockingError = t.step_func(function (error) {
+ assert_unreached("writeDataNonBlocking() error callback invoked: name:" + error.name + "msg:" + error.message);
+ });
+
+ fileHandleWrite = tizen.filesystem.openFile("documents/file", "w");
+ conversionTable = getTypeConversionExceptions("functionObject", true);
+ for (i = 0; i < conversionTable.length; i++) {
+ writeDataNonBlockingError = conversionTable[i][0];
+
+ assert_throws({name: exceptionName}, function () {
+ fileHandleWrite.writeDataNonBlocking(dataToWrite, writeDataNonBlockingSuccess, writeDataNonBlockingError);
+ }, exceptionName + " should be thrown - given incorrect errorCallback.");
+ }
+ t.done();
+});
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileHandle_writeDataNonBlocking_onsuccess_TypeMismatch</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileHandle_writeDataNonBlocking_onsuccess_TypeMismatch
+//==== LABEL Check if FileHandle::writeDataNonBlocking() method throws exception for wrong type of onsuccess
+//==== SPEC Tizen Web API:IO:Filesystem:FileHandle:writeDataNonBlocking M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P2
+//==== TEST_CRITERIA MC
+
+var t = async_test(document.title), dataToWrite = new Uint8Array([11, 21, 31, 71, 81, 91]), writeDataNonBlockingSuccess, writeDataNonBlockingError,
+ fileHandleWrite, i, conversionTable, exceptionName = "TypeMismatchError";
+
+t.step(function () {
+ add_result_callback(function () {
+ try {
+ fileHandleWrite.close();
+ tizen.filesystem.deleteFile("documents/file");
+ } catch (err) {
+ }
+ });
+
+ writeDataNonBlockingSuccess = t.step_func(function (data) {
+ });
+
+ writeDataNonBlockingError = t.step_func(function (error) {
+ assert_unreached("writeDataNonBlocking() error callback invoked: name:" + error.name + "msg:" + error.message);
+ });
+
+ fileHandleWrite = tizen.filesystem.openFile("documents/file", "w");
+ conversionTable = getTypeConversionExceptions("functionObject", true);
+ for (i = 0; i < conversionTable.length; i++) {
+ writeDataNonBlockingSuccess = conversionTable[i][0];
+
+ assert_throws({name: exceptionName}, function () {
+ fileHandleWrite.writeDataNonBlocking(dataToWrite, writeDataNonBlockingSuccess, writeDataNonBlockingError);
+ }, exceptionName + " should be thrown - given incorrect successCallback.");
+ }
+ t.done();
+});
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileHandle_writeDataNonBlocking_successCallback_invalid_cb</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileHandle_writeDataNonBlocking_successCallback_invalid_cb
+//==== LABEL Check if FileHandle::writeDataNonBlocking() method throws exception when successCallback is invalid
+//==== SPEC Tizen Web API:IO:Filesystem:FileHandle:writeDataNonBlocking M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P2
+//==== ONLOAD_DELAY 90
+//==== TEST_CRITERIA MTCB
+
+var t = async_test(document.title), dataToWrite = new Uint8Array([11, 21, 31, 71, 81, 91]), invalidCallback,
+ writeDataNonBlockingError, fileHandleWrite;
+
+t.step(function () {
+ add_result_callback(function () {
+ try {
+ fileHandleWrite.close();
+ tizen.filesystem.deleteFile("documents/file");
+ } catch (err) {
+ }
+ });
+
+ invalidCallback = {
+ onsuccess: t.step_func(function (data) {
+ assert_unreached("Invalid callback invoked");
+ })
+ };
+
+ writeDataNonBlockingError = t.step_func(function (error) {
+ assert_unreached("writeDataNonBlocking() error callback invoked: name:" + error.name + "msg:" + error.message);
+ });
+
+ fileHandleWrite = tizen.filesystem.openFile("documents/file", "w");
+ assert_throws(TYPE_MISMATCH_EXCEPTION, function () {
+ fileHandleWrite.writeDataNonBlocking(dataToWrite, invalidCallback, writeDataNonBlockingError);
+ }, "given incorrect successCallback");
+ t.done();
+});
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileHandle_writeDataNonBlocking_with_onerror</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileHandle_writeDataNonBlocking_with_onerror
+//==== LABEL Check if FileHandle::writeDataNonBlocking() method works properly with onerror
+//==== SPEC Tizen Web API:IO:Filesystem:FileHandle:writeDataNonBlocking M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P1
+//==== ONLOAD_DELAY 90
+//==== TEST_CRITERIA MOA MR MAST
+
+var t = async_test(document.title), dataToWrite = new Uint8Array([11, 21, 31, 71, 81, 91]), writeDataNonBlockingSuccess, writeDataNonBlockingError,
+ readDataNonBlockingSuccess, readDataNonBlockingError, fileHandleWrite, retVal, fileHandleRead;
+
+t.step(function () {
+ add_result_callback(function () {
+ try {
+ tizen.filesystem.deleteFile("documents/file");
+ } catch (err) {
+ }
+ });
+
+ writeDataNonBlockingSuccess = t.step_func(function () {
+ });
+
+ writeDataNonBlockingError = t.step_func(function (error) {
+ assert_unreached("writeDataNonBlocking() error callback invoked: name:" + error.name + "msg:" + error.message);
+ });
+
+ readDataNonBlockingSuccess = t.step_func(function (data) {
+ assert_array_equals(data, dataToWrite, "Data read from file is not right");
+ fileHandleRead.close();
+ t.done();
+ });
+
+ readDataNonBlockingError = t.step_func(function (error) {
+ assert_unreached("readDataNonBlocking() error callback invoked: name:" + error.name + "msg:" + error.message);
+ });
+
+ fileHandleWrite = tizen.filesystem.openFile("documents/file", "w");
+ retVal = fileHandleWrite.writeDataNonBlocking(dataToWrite, writeDataNonBlockingSuccess, writeDataNonBlockingError);
+ assert_equals(retVal, undefined, "return value should be undefined");
+ fileHandleWrite.close();
+
+ fileHandleRead = tizen.filesystem.openFile("documents/file", "r");
+ fileHandleRead.readDataNonBlocking(readDataNonBlockingSuccess, readDataNonBlockingError);
+});
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileHandle_writeData_IOError</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileHandle_writeData_IOError
+//==== LABEL Check if FileHandle::writeData() method with file handle closed throws IOError
+//==== SPEC Tizen Web API:IO:Filesystem:FileHandle:writeData M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P2
+//==== TEST_CRITERIA MC
+
+test(function () {
+ var dataToWrite = new Uint8Array([11, 21, 31, 71, 81, 91]), fileHandleWrite, fileHandleRead;
+
+ add_result_callback(function () {
+ try {
+ tizen.filesystem.deleteFile("documents/file");
+ } catch (err) {
+ }
+ });
+
+ fileHandleWrite = tizen.filesystem.openFile("documents/file", "w");
+ fileHandleWrite.close();
+ assert_throws(IO_EXCEPTION, function () {
+ fileHandleWrite.writeData(dataToWrite);
+ }, "IOError should be thrown - file handle closed.");
+}, document.title);
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileHandle_writeData_data_TypeMismatch</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileHandle_writeData_data_TypeMismatch
+//==== LABEL Check if FileHandle:writeData() throws exception when data type is incorrect
+//==== SPEC Tizen Web API:IO:Filesystem:FileHandle:writeData M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P2
+//==== ONLOAD_DELAY 90
+//==== TEST_CRITERIA MC
+
+test(function () {
+ var fileHandleWrite, i, conversionTable, exceptionName = "TypeMismatchError";
+
+ add_result_callback(function () {
+ try {
+ fileHandleWrite.close();
+ tizen.filesystem.deleteFile("documents/file");
+ } catch (err) {
+ }
+ });
+
+ fileHandleWrite = tizen.filesystem.openFile("documents/file", "w");
+ conversionTable = getTypeConversionExceptions("array", false);
+ for (i = 0; i < conversionTable.length; i++) {
+ dataToWrite = conversionTable[i][0];
+
+ assert_throws({name: exceptionName}, function () {
+ fileHandleWrite.writeData(dataToWrite);
+ }, exceptionName + " should be thrown - given incorrect blob.");
+ }
+}, document.title);
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileHandle_writeData_exist</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileHandle_writeData_exist
+//==== LABEL Check if FileHandle::writeData() method exists
+//==== SPEC Tizen Web API:IO:Filesystem:FileHandle:writeData M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P0
+//==== TEST_CRITERIA ME
+
+test(function () {
+ var fileHandleWrite;
+
+ add_result_callback(function () {
+ try {
+ fileHandleWrite.close();
+ tizen.filesystem.deleteFile("documents/file");
+ } catch (err) {
+ }
+ });
+
+ fileHandleWrite = tizen.filesystem.openFile("documents/file", "w");
+ check_method_exists(fileHandleWrite, "writeData");
+}, document.title);
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileHandle_writeData_misarg</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileHandle_writeData_misarg
+//==== LABEL Check if FileHandle::writeData() method with missing mandatory argument throws exception
+//==== SPEC Tizen Web API:IO:Filesystem:FileHandle:writeData M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P2
+//==== TEST_CRITERIA MMA
+
+test(function () {
+ var fileHandleWrite;
+
+ add_result_callback(function () {
+ try {
+ fileHandleWrite.close();
+ tizen.filesystem.deleteFile("documents/file");
+ } catch (err) {
+ }
+ });
+
+ fileHandleWrite = tizen.filesystem.openFile("documents/file", "w");
+ assert_throws(TYPE_MISMATCH_EXCEPTION, function () {
+ fileHandleWrite.writeData();
+ }, "TypeMismatchError should be thrown.");
+}, document.title);
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileHandle_writeString</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileHandle_writeString
+//==== LABEL Check if FileHandle::writeString() method works properly
+//==== SPEC Tizen Web API:IO:Filesystem:FileHandle:writeString M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P1
+//==== TEST_CRITERIA MR MMINA MAST
+
+test(function () {
+ var fileHandleWrite, fileHandleRead, fileContents, retVal, content = "Lorem ipsum dolor sit amet...";
+
+ add_result_callback(function () {
+ try {
+ tizen.filesystem.deleteFile("documents/file");
+ } catch (err) {
+ }
+ });
+
+ fileHandleWrite = tizen.filesystem.openFile("documents/file", "w");
+ retVal = fileHandleWrite.writeString(content);
+ assert_type(retVal, "long long", "The type returned should be string type.");
+ fileHandleWrite.close();
+
+ fileHandleRead = tizen.filesystem.openFile("documents/file", "r");
+ fileContents = fileHandleRead.readString();
+ assert_equals(fileContents, content, "the read content should be same as the written content.");
+ fileHandleRead.close();
+}, document.title);
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileHandle_writeStringNonBlocking</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileHandle_writeStringNonBlocking
+//==== LABEL Check if FileHandle::writeStringNonBlocking() method works properly
+//==== SPEC Tizen Web API:IO:Filesystem:FileHandle:writeStringNonBlocking M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P1
+//==== ONLOAD_DELAY 90
+//==== TEST_CRITERIA MR MMINA
+
+var t = async_test(document.title), fileHandleWrite, retVal;
+
+t.step(function () {
+ add_result_callback(function () {
+ try {
+ fileHandleWrite.close();
+ tizen.filesystem.deleteFile("documents/file");
+ } catch (err) {
+ }
+ });
+
+ fileHandleWrite = tizen.filesystem.openFile("documents/file", "w");
+ retVal = fileHandleWrite.writeStringNonBlocking("Lorem ipsum dolor sit amet...");
+ assert_equals(retVal, undefined, "return value should be undefined");
+ t.done();
+});
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileHandle_writeStringNonBlocking_NotSupportedError</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileHandle_writeStringNonBlocking_NotSupportedError
+//==== LABEL Check if writeStringNonBlocking() method with not-supported encoding throws NotSupportedError
+//==== SPEC Tizen Web API:IO:Filesystem:FileHandle:writeStringNonBlocking M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P2
+//==== ONLOAD_DELAY 90
+//==== TEST_CRITERIA MC
+
+var t = async_test(document.title), writeStringNonBlockingSuccess, writeStringNonBlockingError, fileHandleWrite;
+
+t.step(function () {
+ add_result_callback(function () {
+ try {
+ fileHandleWrite.close();
+ tizen.filesystem.deleteFile("documents/file");
+ } catch (err) {
+ }
+ });
+
+ writeStringNonBlockingSuccess = t.step_func(function (bytesCount) {
+ });
+
+ writeStringNonBlockingError = t.step_func(function (error) {
+ assert_unreached("writeStringNonBlocking() error callback invoked: name:" + error.name + "msg:" + error.message);
+ });
+
+ fileHandleWrite = tizen.filesystem.openFile("documents/file", "w");
+ assert_throws(NOT_SUPPORTED_EXCEPTION, function () {
+ fileHandleWrite.writeStringNonBlocking("Lorem ipsum dolor sit amet...", writeStringNonBlockingSuccess, writeStringNonBlockingError, "wrong-encoding");
+ }, "NotSupportedError should be thrown - invalid encoding.");
+ t.done();
+});
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileHandle_writeStringNonBlocking_errorCallback_invalid_cb</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileHandle_writeStringNonBlocking_errorCallback_invalid_cb
+//==== LABEL Check if FileHandle::writeStringNonBlocking() method throws exception when errorCallback is invalid
+//==== SPEC Tizen Web API:IO:Filesystem:FileHandle:writeStringNonBlocking M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P2
+//==== ONLOAD_DELAY 90
+//==== TEST_CRITERIA MTCB
+
+var t = async_test(document.title), writeStringNonBlockingSuccess, invalidCallback, fileHandleWrite;
+
+t.step(function () {
+ add_result_callback(function () {
+ try {
+ fileHandleWrite.close();
+ tizen.filesystem.deleteFile("documents/file");
+ } catch (err) {
+ }
+ });
+
+ writeStringNonBlockingSuccess = t.step_func(function (bytesCount) {
+ assert_unreached("Should not be invoked writeStringNonBlocking SuccessCallback");
+ });
+
+ invalidCallback = {
+ onerror: t.step_func(function () {
+ assert_unreached("Invalid callback invoked");
+ })
+ };
+
+ fileHandleWrite = tizen.filesystem.openFile("documents/file", "w");
+ assert_throws(TYPE_MISMATCH_EXCEPTION, function () {
+ fileHandleWrite.writeStringNonBlocking("Lorem ipsum dolor sit amet...", writeStringNonBlockingSuccess, invalidCallback);
+ }, "given incorrect errorCallback");
+ t.done();
+});
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileHandle_writeStringNonBlocking_errorCallback_invoked_IOError</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileHandle_writeStringNonBlocking_errorCallback_invoked_IOError
+//==== LABEL Check if errorcallback of FileHandle::writeStringNonBlocking() method can be invoked if input/output error occurs
+//==== SPEC Tizen Web API:IO:Filesystem:FileHandle:writeStringNonBlocking M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P2
+//==== ONLOAD_DELAY 90
+//==== TEST_CRITERIA MERRCB
+
+var t = async_test(document.title), writeStringNonBlockingSuccess, writeStringNonBlockingError, fileHandleWrite;
+
+t.step(function () {
+ add_result_callback(function () {
+ try {
+ tizen.filesystem.deleteFile("documents/file");
+ } catch (err) {
+ }
+ });
+
+ writeStringNonBlockingSuccess = t.step_func(function (bytesCount) {
+ assert_unreached("Should not be invoked writeStringNonBlocking SuccessCallback");
+ });
+
+ writeStringNonBlockingError = t.step_func(function (error) {
+ assert_equals(error.name, "IOError", "expect to throw an IOError exception");
+ t.done();
+ });
+
+ fileHandleWrite = tizen.filesystem.openFile("documents/file", "w");
+ fileHandleWrite.close();
+ fileHandleWrite.writeStringNonBlocking("Lorem ipsum dolor sit amet...", writeStringNonBlockingSuccess, writeStringNonBlockingError, "UTF-8");
+});
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileHandle_writeStringNonBlocking_exist</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileHandle_writeStringNonBlocking_exist
+//==== LABEL Check if FileHandle::writeStringNonBlocking() method exists
+//==== SPEC Tizen Web API:IO:Filesystem:FileHandle:writeStringNonBlocking M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P0
+//==== TEST_CRITERIA ME
+
+test(function () {
+ var fileHandleWrite;
+
+ add_result_callback(function () {
+ try {
+ fileHandleWrite.close();
+ tizen.filesystem.deleteFile("documents/file");
+ } catch (err) {
+ }
+ });
+
+ fileHandleWrite = tizen.filesystem.openFile("documents/file", "w");
+ check_method_exists(fileHandleWrite, "writeStringNonBlocking");
+}, document.title);
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileHandle_writeStringNonBlocking_onerror_TypeMismatch</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileHandle_writeStringNonBlocking_onerror_TypeMismatch
+//==== LABEL Check if FileHandle::writeStringNonBlocking() method throws exception for wrong type of onerror
+//==== SPEC Tizen Web API:IO:Filesystem:FileHandle:writeStringNonBlocking M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P2
+//==== ONLOAD_DELAY 90
+//==== TEST_CRITERIA MC
+
+var t = async_test(document.title), writeStringNonBlockingSuccess, writeStringNonBlockingError,
+ fileHandleWrite, i, conversionTable, exceptionName = "TypeMismatchError";
+
+t.step(function () {
+ add_result_callback(function () {
+ try {
+ fileHandleWrite.close();
+ tizen.filesystem.deleteFile("documents/file");
+ } catch (err) {
+ }
+ });
+
+ writeStringNonBlockingSuccess = t.step_func(function (bytesCount) {
+ assert_unreached("Should not be invoked to writeStringNonBlockingSuccesscallback");
+ });
+
+ fileHandleWrite = tizen.filesystem.openFile("documents/file", "w");
+
+ conversionTable = getTypeConversionExceptions("functionObject", true);
+ for (i = 0; i < conversionTable.length; i++) {
+ writeStringNonBlockingError = conversionTable[i][0];
+
+ assert_throws({name: exceptionName}, function () {
+ fileHandleWrite.writeStringNonBlocking("Lorem ipsum dolor sit amet...", writeStringNonBlockingSuccess, writeStringNonBlockingError);
+ }, exceptionName + " should be thrown - given incorrect errorCallback.");
+ }
+ t.done();
+});
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileHandle_writeStringNonBlocking_onsuccess_TypeMismatch</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileHandle_writeStringNonBlocking_onsuccess_TypeMismatch
+//==== LABEL Check if FileHandle::writeStringNonBlocking() method throws exception for wrong type of onsuccess
+//==== SPEC Tizen Web API:IO:Filesystem:FileHandle:writeStringNonBlocking M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P2
+//==== ONLOAD_DELAY 90
+//==== TEST_CRITERIA MC
+
+var t = async_test(document.title), writeStringNonBlockingSuccess, writeStringNonBlockingError,
+ fileHandleWrite, i, conversionTable, exceptionName = "TypeMismatchError";
+
+t.step(function () {
+ add_result_callback(function () {
+ try {
+ fileHandleWrite.close();
+ tizen.filesystem.deleteFile("documents/file");
+ } catch (err) {
+ }
+ });
+
+ writeStringNonBlockingError = t.step_func(function (error) {
+ assert_unreached("Should be invoked to writeStringNonBlockingErrorcallback");
+ });
+
+ fileHandleWrite = tizen.filesystem.openFile("documents/file", "w");
+
+ conversionTable = getTypeConversionExceptions("functionObject", true);
+ for (i = 0; i < conversionTable.length; i++) {
+ writeStringNonBlockingSuccess = conversionTable[i][0];
+
+ assert_throws({name: exceptionName}, function () {
+ fileHandleWrite.writeStringNonBlocking("Lorem ipsum dolor sit amet...", writeStringNonBlockingSuccess, writeStringNonBlockingError);
+ }, exceptionName + " should be thrown - given incorrect successCallback.");
+ }
+ t.done();
+});
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileHandle_writeStringNonBlocking_successCallback_invalid_cb</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileHandle_writeStringNonBlocking_successCallback_invalid_cb
+//==== LABEL Check if FileHandle::writeStringNonBlocking() method throws exception when successCallback is invalid
+//==== SPEC Tizen Web API:IO:Filesystem:FileHandle:writeStringNonBlocking M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P2
+//==== ONLOAD_DELAY 90
+//==== TEST_CRITERIA MTCB
+
+var t = async_test(document.title), invalidCallback, writeStringNonBlockingError, fileHandleWrite;
+
+t.step(function () {
+ add_result_callback(function () {
+ try {
+ fileHandleWrite.close();
+ tizen.filesystem.deleteFile("documents/file");
+ } catch (err) {
+ }
+ });
+
+ invalidCallback = {
+ onsuccess: t.step_func(function (bytesCount) {
+ assert_unreached("Invalid callback invoked");
+ })
+ };
+
+ writeStringNonBlockingError = t.step_func(function (error) {
+ assert_unreached("writeStringNonBlocking() error callback invoked: name:" + error.name + "msg:" + error.message);
+ });
+
+ fileHandleWrite = tizen.filesystem.openFile("documents/file", "w");
+ assert_throws(TYPE_MISMATCH_EXCEPTION, function () {
+ fileHandleWrite.writeStringNonBlocking("Lorem ipsum dolor sit amet...", invalidCallback, writeStringNonBlockingError);
+ }, "given incorrect errorCallback");
+ t.done();
+});
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileHandle_writeStringNonBlocking_with_outputEncoding</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileHandle_writeStringNonBlocking_with_outputEncoding
+//==== LABEL Check if FileHandle::writeStringNonBlocking() method works properly with outputEncoding
+//==== SPEC Tizen Web API:IO:Filesystem:FileHandle:writeStringNonBlocking M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P1
+//==== ONLOAD_DELAY 90
+//==== TEST_CRITERIA MOA MR MAST
+
+var t = async_test(document.title), writeStringNonBlockingSuccess, writeStringNonBlockingError,
+ readStringNonBlockingSuccess, readStringNonBlockingError,
+ fileHandleWrite, fileHandleRead, retVal, content = "Lorem ipsum dolor sit amet...";
+
+t.step(function () {
+ add_result_callback(function () {
+ try {
+ tizen.filesystem.deleteFile("documents/file");
+ } catch (err) {
+ }
+ });
+
+ writeStringNonBlockingSuccess = t.step_func(function (bytesCount) {
+ });
+
+ writeStringNonBlockingError = t.step_func(function (error) {
+ assert_unreached("writeStringNonBlocking() error callback invoked: name:" + error.name + "msg:" + error.message);
+ });
+
+ readStringNonBlockingSuccess = t.step_func(function (output) {
+ assert_equals(output, content.substring(0, 5), "The read content should be same as the written content.");
+ fileHandleRead.close();
+ t.done();
+ });
+
+ readStringNonBlockingError = t.step_func(function (error) {
+ assert_unreached("readStringNonBlocking() error callback invoked: name:" + error.name + "msg:" + error.message);
+ });
+
+ fileHandleWrite = tizen.filesystem.openFile("documents/file", "w");
+ retVal = fileHandleWrite.writeStringNonBlocking(content, writeStringNonBlockingSuccess, writeStringNonBlockingError, "UTF-8");
+ assert_equals(retVal, undefined, "return value should be undefined");
+ fileHandleWrite.close();
+
+ fileHandleRead = tizen.filesystem.openFile("documents/file", "r");
+ fileHandleRead.readStringNonBlocking(readStringNonBlockingSuccess, readStringNonBlockingError, 5, "UTF-8");
+});
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileHandle_writeString_IOError</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileHandle_writeString_IOError
+//==== LABEL Check if FileHandle::writeString() method with file handle closed throws IOError
+//==== SPEC Tizen Web API:IO:Filesystem:FileHandle:writeString M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P2
+//==== TEST_CRITERIA MC
+
+test(function () {
+ var fileHandleWrite, content = "Lorem ipsum dolor sit amet...";
+
+ add_result_callback(function () {
+ try {
+ tizen.filesystem.deleteFile("documents/file");
+ } catch (err) {
+ }
+ });
+
+ fileHandleWrite = tizen.filesystem.openFile("documents/file", "w");
+ fileHandleWrite.close();
+ assert_throws(IO_EXCEPTION, function () {
+ fileHandleWrite.writeString(content);
+ }, "IOError should be thrown - file handle closed.");
+}, document.title);
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileHandle_writeString_NotSupportedError</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileHandle_writeString_NotSupportedError
+//==== LABEL Check if FileHandle::writeString() method with invalid encoding throws NotSupportedError
+//==== SPEC Tizen Web API:IO:Filesystem:FileHandle:writeString M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P2
+//==== TEST_CRITERIA MC
+
+test(function () {
+ var fileHandleWrite, content = "Lorem ipsum dolor sit amet...";
+
+ add_result_callback(function () {
+ try {
+ fileHandleWrite.close();
+ tizen.filesystem.deleteFile("documents/file");
+ } catch (err) {
+ }
+ });
+
+ fileHandleWrite = tizen.filesystem.openFile("documents/file", "w");
+ assert_throws(NOT_SUPPORTED_EXCEPTION, function () {
+ fileHandleWrite.writeString(content, "wrong-encoding");
+ }, "NotSupportedError should be thrown - invalid encoding.");
+}, document.title);
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileHandle_writeString_exist</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileHandle_writeString_exist
+//==== LABEL Check if FileHandle::writeString() method exists
+//==== SPEC Tizen Web API:IO:Filesystem:FileHandle:writeString M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P0
+//==== TEST_CRITERIA ME
+
+test(function () {
+ var fileHandleWrite, fileContents;
+
+ add_result_callback(function () {
+ try {
+ fileHandleWrite.close();
+ tizen.filesystem.deleteFile("documents/file");
+ } catch (err) {
+ }
+ });
+
+ fileHandleWrite = tizen.filesystem.openFile("documents/file", "w");
+ check_method_exists(fileHandleWrite, "writeString");
+}, document.title);
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileHandle_writeString_with_outputEncoding</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileHandle_writeString_with_outputEncoding
+//==== LABEL Check if FileHandle::writeString() method works properly with outputEncoding
+//==== SPEC Tizen Web API:IO:Filesystem:FileHandle:writeString M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P1
+//==== TEST_CRITERIA MOA MR MAST
+
+test(function () {
+ var fileHandleWrite, fileHandleRead, fileContents, retVal, content = "Lorem ipsum dolor sit amet...";
+
+ add_result_callback(function () {
+ try {
+ tizen.filesystem.deleteFile("documents/file");
+ } catch (err) {
+ }
+ });
+
+ fileHandleWrite = tizen.filesystem.openFile("documents/file", "w");
+ retVal = fileHandleWrite.writeString(content, "UTF-8");
+ assert_type(retVal, "long long", "The type returned should be of string type.");
+ fileHandleWrite.close();
+
+ fileHandleRead = tizen.filesystem.openFile("documents/file", "r");
+ fileContents = fileHandleRead.readString();
+ assert_equals(fileContents, content, "the read content should be same as the written content.");
+ fileHandleRead.close();
+}, document.title);
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileSystemManager_copyDirectory</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileSystemManager_copyDirectory
+//==== LABEL Check if FileSystemManager::copyDirectory() method works properly
+//==== SPEC Tizen Web API:IO:Filesystem:FileSystemManager:copyDirectory M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P1
+//==== TEST_CRITERIA MR MMINA
+
+test(function () {
+ var retVal;
+
+ add_result_callback(function () {
+ try {
+ tizen.filesystem.deleteDirectory("documents/foo_dir", true);
+ tizen.filesystem.deleteDirectory("documents/bar_dir", true);
+ } catch (err) {
+ }
+ });
+
+ tizen.filesystem.createDirectory("documents/foo_dir");
+ tizen.filesystem.createDirectory("documents/foo_dir/test");
+ tizen.filesystem.createDirectory("documents/bar_dir");
+ retVal = tizen.filesystem.copyDirectory("documents/foo_dir", "documents/bar_dir");
+ assert_equals(retVal, undefined, "return value should be undefined");
+}, document.title);
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileSystemManager_copyDirectory_InvalidValuesError</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileSystemManager_copyDirectory_InvalidValuesError
+//==== LABEL Check if FileSystemManager::copyDirectory() method with invalid path throws InvalidValuesError
+//==== SPEC Tizen Web API:IO:Filesystem:FileSystemManager:copyDirectory M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P2
+//==== TEST_CRITERIA MC
+
+test(function () {
+ assert_throws(INVALID_VALUES_EXCEPTION, function () {
+ tizen.filesystem.copyDirectory("notexist/folder", "documents/bar_dir");
+ }, "InvalidValuesError should be thrown - invalid path.");
+}, document.title);
+
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileSystemManager_copyDirectory_errorCallback_invalid_cb</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileSystemManager_copyDirectory_errorCallback_invalid_cb
+//==== LABEL Check if FileSystemManager::copyDirectory() method throws exception when errorCallback is invalid
+//==== SPEC Tizen Web API:IO:Filesystem:FileSystemManager:copyDirectory M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P2
+//==== ONLOAD_DELAY 90
+//==== TEST_CRITERIA MTCB
+
+var t = async_test(document.title), copyDirectorySuccess, invalidCallback;
+
+t.step(function () {
+ add_result_callback(function () {
+ try {
+ tizen.filesystem.deleteDirectory("documents/foo_dir", true);
+ tizen.filesystem.deleteDirectory("documents/bar_dir", true);
+ } catch (err) {
+ }
+ });
+
+ copyDirectorySuccess = t.step_func(function () {
+ assert_unreached("Should not be invoked copyDirectory SuccessCallback");
+ });
+
+ invalidCallback = {
+ onerror: t.step_func(function (error) {
+ assert_unreached("Invalid callback invoked");
+ })
+ };
+
+ tizen.filesystem.createDirectory("documents/foo_dir");
+ tizen.filesystem.createDirectory("documents/bar_dir");
+
+ assert_throws(TYPE_MISMATCH_EXCEPTION, function () {
+ tizen.filesystem.copyDirectory("documents/foo_dir", "documents/bar_dir", true, copyDirectorySuccess, invalidCallback);
+ }, "given incorrect errorCallback");
+ t.done();
+});
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileSystemManager_copyDirectory_errorCallback_invoked_NotFoundError</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileSystemManager_copyDirectory_errorCallback_invoked_NotFoundError
+//==== LABEL Check if FileSystemManager::copyDirectory() method throws NotFoundError when path not exists
+//==== SPEC Tizen Web API:IO:Filesystem:FileSystemManager:copyDirectory M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P2
+//==== ONLOAD_DELAY 90
+//==== TEST_CRITERIA MERRCB
+
+var t = async_test(document.title), copyDirectorySuccess, copyDirectoryError;
+
+t.step(function () {
+ copyDirectorySuccess = t.step_func(function () {
+ assert_unreached("Should not be invoked copyDirectory SuccessCallback");
+ });
+
+ copyDirectoryError = t.step_func(function (error) {
+ assert_equals(error.name, "NotFoundError", "expect to throw an NotFoundError exception");
+ t.done();
+ });
+
+ tizen.filesystem.copyDirectory("documents/wrong_dir", "documents/bar_dir", true, copyDirectorySuccess, copyDirectoryError);
+});
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileSystemManager_copyDirectory_exist</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileSystemManager_copyDirectory_exist
+//==== LABEL Check if FileSystemManager::copyDirectory() method exists
+//==== SPEC Tizen Web API:IO:Filesystem:FileSystemManager:copyDirectory M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P0
+//==== TEST_CRITERIA ME
+
+test(function () {
+ check_method_exists(tizen.filesystem, "copyDirectory");
+}, document.title);
+
+</script>
+</body>
+</html>
\ No newline at end of file
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileSystemManager_copyDirectory_misarg</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileSystemManager_copyDirectory_misarg
+//==== LABEL Check if FileSystemManager::copyDirectory() method with missing mandatory argument throws exception
+//==== SPEC Tizen Web API:IO:Filesystem:FileSystemManager:copyDirectory M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P2
+//==== TEST_CRITERIA MMA
+
+test(function () {
+ assert_throws(INVALID_VALUES_EXCEPTION, function () {
+ tizen.filesystem.copyDirectory();
+ }, "InvalidValuesError should be thrown.");
+}, document.title);
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileSystemManager_copyDirectory_onerror_TypeMismatch</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileSystemManager_copyDirectory_onerror_TypeMismatch
+//==== LABEL Check if FileSystemManager::copyDirectory() method throws exception for wrong type of onerror
+//==== SPEC Tizen Web API:IO:Filesystem:FileSystemManager:copyDirectory M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P2
+//==== ONLOAD_DELAY 90
+//==== TEST_CRITERIA MC
+
+var t = async_test(document.title), copyDirectorySuccess, copyDirectoryError,
+ i, conversionTable, exceptionName = "TypeMismatchError";
+
+t.step(function () {
+ add_result_callback(function () {
+ try {
+ tizen.filesystem.deleteDirectory("documents/foo_dir", true);
+ tizen.filesystem.deleteDirectory("documents/bar_dir", true);
+ } catch (err) {
+ }
+ });
+
+ copyDirectorySuccess = t.step_func(function () {
+ assert_unreached("Should not be invoked to copyDirectory Successcallback");
+ });
+
+ tizen.filesystem.createDirectory("documents/foo_dir");
+ tizen.filesystem.createDirectory("documents/bar_dir");
+
+ conversionTable = getTypeConversionExceptions("functionObject", true);
+ for (i = 0; i < conversionTable.length; i++) {
+ copyDirectoryError = conversionTable[i][0];
+
+ assert_throws({name: exceptionName}, function () {
+ tizen.filesystem.copyDirectory("documents/foo_dir", "documents/bar_dir", true, copyDirectorySuccess, copyDirectoryError);
+ }, exceptionName + " should be thrown - given incorrect errorCallback.");
+ }
+ t.done();
+});
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileSystemManager_copyDirectory_onsuccess_TypeMismatch</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileSystemManager_copyDirectory_onsuccess_TypeMismatch
+//==== LABEL Check if FileSystemManager::copyDirectory() method throws exception for wrong type of onsuccess
+//==== SPEC Tizen Web API:IO:Filesystem:FileSystemManager:copyDirectory M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P2
+//==== ONLOAD_DELAY 90
+//==== TEST_CRITERIA MC
+
+var t = async_test(document.title), copyDirectorySuccess, copyDirectoryError,
+ i, conversionTable, exceptionName = "TypeMismatchError";
+
+t.step(function () {
+ add_result_callback(function () {
+ try {
+ tizen.filesystem.deleteDirectory("documents/foo_dir", true);
+ tizen.filesystem.deleteDirectory("documents/bar_dir", true);
+ } catch (err) {
+ }
+ });
+
+ copyDirectoryError = t.step_func(function (error) {
+ assert_unreached("copyDirectory() error callback invoked: name:" + error.name + "msg:" + error.message);
+ });
+
+ tizen.filesystem.createDirectory("documents/foo_dir");
+ tizen.filesystem.createDirectory("documents/bar_dir");
+
+ conversionTable = getTypeConversionExceptions("functionObject", true);
+ for (i = 0; i < conversionTable.length; i++) {
+ copyDirectorySuccess = conversionTable[i][0];
+
+ assert_throws({name: exceptionName}, function () {
+ tizen.filesystem.copyDirectory("documents/foo_dir", "documents/bar_dir", true, copyDirectorySuccess, copyDirectoryError);
+ }, exceptionName + " should be thrown - given incorrect successCallback.");
+ }
+ t.done();
+});
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileSystemManager_copyDirectory_successCallback_invalid_cb</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileSystemManager_copyDirectory_successCallback_invalid_cb
+//==== LABEL Check if FileSystemManager::copyDirectory() method throws exception when successCallback is invalid
+//==== SPEC Tizen Web API:IO:Filesystem:FileSystemManager:copyDirectory M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P2
+//==== ONLOAD_DELAY 90
+//==== TEST_CRITERIA MTCB
+
+var t = async_test(document.title), invalidCallback, copyDirectoryError;
+
+t.step(function () {
+ add_result_callback(function () {
+ try {
+ tizen.filesystem.deleteDirectory("documents/foo_dir", true);
+ tizen.filesystem.deleteDirectory("documents/bar_dir", true);
+ } catch (err) {
+ }
+ });
+
+ invalidCallback = {
+ onsuccess: t.step_func(function () {
+ assert_unreached("Invalid callback invoked");
+ })
+ };
+
+ copyDirectoryError = t.step_func(function (error) {
+ assert_unreached("copyDirectory() error callback invoked: name:" + error.name + "msg:" + error.message);
+ });
+
+ tizen.filesystem.createDirectory("documents/foo_dir");
+ tizen.filesystem.createDirectory("documents/bar_dir");
+ assert_throws(TYPE_MISMATCH_EXCEPTION, function () {
+ tizen.filesystem.copyDirectory("documents/foo_dir", "documents/bar_dir", true, invalidCallback, copyDirectoryError);
+ }, "given incorrect successCallback");
+ t.done();
+});
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileSystemManager_copyDirectory_with_errorCallback</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileSystemManager_copyDirectory_with_errorCallback
+//==== LABEL Check if FileSystemManager::copyDirectory() method works properly with errorCallback
+//==== SPEC Tizen Web API:IO:Filesystem:FileSystemManager:copyDirectory M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P1
+//==== ONLOAD_DELAY 90
+//==== TEST_CRITERIA MOA MR MAST
+
+var t = async_test(document.title), copyDirectorySuccess, copyDirectoryError, retVal;
+
+t.step(function () {
+ add_result_callback(function () {
+ try {
+ tizen.filesystem.deleteDirectory("documents/foo_dir", true);
+ tizen.filesystem.deleteDirectory("documents/bar_dir", true);
+ } catch (err) {
+ }
+ });
+
+ copyDirectorySuccess = t.step_func(function () {
+ assert_equals(retVal, undefined, "return value should be undefined");
+ assert_true(tizen.filesystem.pathExists("documents/bar_dir/test"), "directory is not copied to the destination path successfully");
+ t.done();
+ });
+
+ copyDirectoryError = t.step_func(function (error) {
+ assert_unreached("copyDirectory() error callback invoked: name:" + error.name + "msg:" + error.message);
+ });
+
+ tizen.filesystem.createDirectory("documents/foo_dir");
+ tizen.filesystem.createDirectory("documents/foo_dir/test");
+ tizen.filesystem.createDirectory("documents/bar_dir");
+ retVal = tizen.filesystem.copyDirectory("documents/foo_dir", "documents/bar_dir", true, copyDirectorySuccess, copyDirectoryError);
+});
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileSystemManager_copyFile</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileSystemManager_copyFile
+//==== LABEL Check if FileSystemManager::copyFile() method works properly
+//==== SPEC Tizen Web API:IO:Filesystem:FileSystemManager:copyFile M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P1
+//==== TEST_CRITERIA MR MMINA
+
+test(function () {
+ var retVal, fileWrite, content = "Lorem ipsum dolor sit amet...";
+
+ add_result_callback(function () {
+ try {
+ tizen.filesystem.deleteFile("documents/foo");
+ tizen.filesystem.deleteDirectory("documents/foo_dir", true);
+ } catch (err) {
+ }
+ });
+
+ tizen.filesystem.createDirectory("documents/foo_dir");
+ fileWrite = tizen.filesystem.openFile("documents/foo", "w");
+ fileWrite.writeString(content);
+ fileWrite.close();
+
+ retVal = tizen.filesystem.copyFile("documents/foo", "documents/foo_dir/renamefoo");
+ assert_equals(retVal, undefined, "return value should be undefined");
+}, document.title);
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileSystemManager_copyFile_InvalidValuesError</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileSystemManager_copyFile_InvalidValuesError
+//==== LABEL Check if FileSystemManager::copyFile() method with invalid path throws InvalidValuesError
+//==== SPEC Tizen Web API:IO:Filesystem:FileSystemManager:copyFile M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P2
+//==== ONLOAD_DELAY 90
+//==== TEST_CRITERIA MC
+
+var t = async_test(document.title), copyFileSuccess, copyFileError;
+
+t.step(function () {
+ copyFileSuccess = t.step_func(function () {
+ });
+
+ copyFileError = t.step_func(function (error) {
+ assert_unreached("copyFile() error callback invoked: name:" + error.name + "msg:" + error.message);
+ });
+
+ assert_throws(INVALID_VALUES_EXCEPTION, function () {
+ tizen.filesystem.copyFile("documents/foo", "notexist/folder", true, copyFileSuccess, copyFileError);
+ }, "InvalidValuesError should be thrown - invalid path.");
+ t.done();
+});
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileSystemManager_copyFile_errorCallback_invalid_cb</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileSystemManager_copyFile_errorCallback_invalid_cb
+//==== LABEL Check if FileSystemManager::copyFile() method throws exception when errorCallback is invalid
+//==== SPEC Tizen Web API:IO:Filesystem:FileSystemManager:copyFile M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P2
+//==== ONLOAD_DELAY 90
+//==== TEST_CRITERIA MTCB
+
+var t = async_test(document.title), copyFileSuccess, invalidCallback;
+
+t.step(function () {
+ add_result_callback(function () {
+ try {
+ tizen.filesystem.deleteFile("documents/foo");
+ tizen.filesystem.deleteDirectory("documents/foo_dir", true);
+ } catch (err) {
+ }
+ });
+
+ copyFileSuccess = t.step_func(function () {
+ assert_unreached("Should not be invoked copyFile SuccessCallback");
+ });
+
+ invalidCallback = {
+ onerror: t.step_func(function (error) {
+ assert_unreached("Invalid callback invoked");
+ })
+ };
+
+ tizen.filesystem.createDirectory("documents/foo_dir");
+ tizen.filesystem.openFile("documents/foo", "w");
+ assert_throws(TYPE_MISMATCH_EXCEPTION, function () {
+ tizen.filesystem.copyFile("documents/foo", "documents/foo_dir", true, copyFileSuccess, invalidCallback);
+ }, "given incorrect errorCallback");
+ t.done();
+});
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileSystemManager_copyFile_errorCallback_invoked_NotFoundError</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileSystemManager_copyFile_errorCallback_invoked_NotFoundError
+//==== LABEL Check if FileSystemManager::copyFile() method throws NotFoundError when path not exists
+//==== SPEC Tizen Web API:IO:Filesystem:FileSystemManager:copyFile M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P2
+//==== ONLOAD_DELAY 90
+//==== TEST_CRITERIA MERRCB
+
+var t = async_test(document.title), copyFileSuccess, copyFileError;
+
+t.step(function () {
+ copyFileSuccess = t.step_func(function () {
+ assert_unreached("Should not be invoked copyFile SuccessCallback");
+ });
+
+ copyFileError = t.step_func(function (error) {
+ assert_equals(error.name, "NotFoundError", "expect to throw an NotFoundError exception");
+ t.done();
+ });
+
+ tizen.filesystem.copyFile("documents/foo", "documents/foo_dir/wrong_dir", true, copyFileSuccess, copyFileError);
+});
+
+</script>
+</body>
+</html>
\ No newline at end of file
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileSystemManager_copyFile_exist</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileSystemManager_copyFile_exist
+//==== LABEL Check if FileSystemManager::copyFile() method exists
+//==== SPEC Tizen Web API:IO:Filesystem:FileSystemManager:copyFile M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P0
+//==== TEST_CRITERIA ME
+
+test(function () {
+ check_method_exists(tizen.filesystem, "copyFile");
+}, document.title);
+
+</script>
+</body>
+</html>
\ No newline at end of file
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileSystemManager_copyFile_misarg</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileSystemManager_copyFile_misarg
+//==== LABEL Check if FileSystemManager::copyFile() method with missing mandatory argument throws exception
+//==== SPEC Tizen Web API:IO:Filesystem:FileSystemManager:copyFile M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P2
+//==== TEST_CRITERIA MMA
+
+test(function () {
+ assert_throws(INVALID_VALUES_EXCEPTION, function () {
+ tizen.filesystem.copyFile();
+ }, "InvalidValuesError should be thrown.");
+}, document.title);
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileSystemManager_copyFile_onerror_TypeMismatch</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileSystemManager_copyFile_onerror_TypeMismatch
+//==== LABEL Check if FileSystemManager::copyFile() method throws exception for wrong type of onerror
+//==== SPEC Tizen Web API:IO:Filesystem:FileSystemManager:copyFile M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P2
+//==== ONLOAD_DELAY 90
+//==== TEST_CRITERIA MC
+
+var t = async_test(document.title), copyFileSuccess, copyFileError,
+ i, conversionTable, exceptionName = "TypeMismatchError";
+
+t.step(function () {
+ add_result_callback(function () {
+ try {
+ tizen.filesystem.deleteFile("documents/foo");
+ tizen.filesystem.deleteDirectory("documents/foo_dir", true);
+ } catch (err) {
+ }
+ });
+
+ copyFileSuccess = t.step_func(function () {
+ assert_unreached("Should not be invoked to copyFile Successcallback");
+ });
+
+ tizen.filesystem.createDirectory("documents/foo_dir");
+ tizen.filesystem.openFile("documents/foo", "w");
+
+ conversionTable = getTypeConversionExceptions("functionObject", true);
+ for (i = 0; i < conversionTable.length; i++) {
+ copyFileError = conversionTable[i][0];
+
+ assert_throws({name: exceptionName}, function () {
+ tizen.filesystem.copyFile("documents/foo", "documents/foo_dir", true, copyFileSuccess, copyFileError);
+ }, exceptionName + " should be thrown - given incorrect errorCallback.");
+ }
+ t.done();
+});
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileSystemManager_copyFile_onsuccess_TypeMismatch</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileSystemManager_copyFile_onsuccess_TypeMismatch
+//==== LABEL Check if FileSystemManager::copyFile() method throws exception for wrong type of onsuccess
+//==== SPEC Tizen Web API:IO:Filesystem:FileSystemManager:copyFile M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P2
+//==== ONLOAD_DELAY 90
+//==== TEST_CRITERIA MC
+
+var t = async_test(document.title), copyFileSuccess, copyFileError,
+ i, conversionTable, exceptionName = "TypeMismatchError";
+
+t.step(function () {
+ add_result_callback(function () {
+ try {
+ tizen.filesystem.deleteFile("documents/foo");
+ tizen.filesystem.deleteDirectory("documents/foo_dir", true);
+ } catch (err) {
+ }
+ });
+
+ copyFileError = t.step_func(function (error) {
+ assert_unreached("copyFile() error callback invoked: name:" + error.name + "msg:" + error.message);
+ });
+
+ tizen.filesystem.createDirectory("documents/foo_dir");
+ tizen.filesystem.openFile("documents/foo", "w");
+
+ conversionTable = getTypeConversionExceptions("functionObject", true);
+ for (i = 0; i < conversionTable.length; i++) {
+ copyFileSuccess = conversionTable[i][0];
+
+ assert_throws({name: exceptionName}, function () {
+ tizen.filesystem.copyFile("documents/foo", "documents/foo_dir", true, copyFileSuccess, copyFileError);
+ }, exceptionName + " should be thrown - given incorrect successCallback.");
+ }
+ t.done();
+});
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileSystemManager_copyFile_successCallback_invalid_cb</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileSystemManager_copyFile_successCallback_invalid_cb
+//==== LABEL Check if FileSystemManager::copyFile() method throws exception when successCallback is invalid
+//==== SPEC Tizen Web API:IO:Filesystem:FileSystemManager:copyFile M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P2
+//==== ONLOAD_DELAY 90
+//==== TEST_CRITERIA MTCB
+
+var t = async_test(document.title), invalidCallback;
+
+t.step(function () {
+ add_result_callback(function () {
+ try {
+ tizen.filesystem.deleteFile("documents/foo");
+ tizen.filesystem.deleteDirectory("documents/foo_dir", true);
+ } catch (err) {
+ }
+ });
+
+ invalidCallback = {
+ onsuccess: t.step_func(function () {
+ assert_unreached("Invalid callback invoked");
+ })
+ };
+
+ tizen.filesystem.createDirectory("documents/foo_dir");
+ tizen.filesystem.openFile("documents/foo", "w");
+ assert_throws(TYPE_MISMATCH_EXCEPTION, function () {
+ tizen.filesystem.copyFile("documents/foo", "documents/foo_dir", true, invalidCallback);
+ }, "given incorrect successCallback");
+ t.done();
+});
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileSystemManager_copyFile_with_errorCallback</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileSystemManager_copyFile_with_errorCallback
+//==== LABEL Check if FileSystemManager::copyFile() method works properly with errorCallback
+//==== SPEC Tizen Web API:IO:Filesystem:FileSystemManager:copyFile M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P1
+//==== ONLOAD_DELAY 90
+//==== TEST_CRITERIA MOA MR MAST
+
+var t = async_test(document.title), copyFileSuccess, copyFileError, retVal;
+
+t.step(function () {
+ add_result_callback(function () {
+ try {
+ tizen.filesystem.deleteFile("documents/foo");
+ tizen.filesystem.deleteDirectory("documents/foo_dir", true);
+ } catch (err) {
+ }
+ });
+
+ copyFileSuccess = t.step_func(function () {
+ assert_equals(retVal, undefined, "return value should be undefined");
+ assert_true(tizen.filesystem.pathExists("documents/foo_dir/foo"), "file is not copied to the destination path successfully");
+ t.done();
+ });
+
+ copyFileError = t.step_func(function (error) {
+ assert_unreached("copyFile() error callback invoked: name:" + error.name + "msg:" + error.message);
+ });
+
+ tizen.filesystem.createDirectory("documents/foo_dir");
+ tizen.filesystem.openFile("documents/foo", "w");
+ retVal = tizen.filesystem.copyFile("documents/foo", "documents/foo_dir/foo", true, copyFileSuccess, copyFileError);
+});
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileSystemManager_createDirectory</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileSystemManager_createDirectory
+//==== LABEL Check if FileSystemManager::createDirectory() method works properly
+//==== SPEC Tizen Web API:IO:Filesystem:FileSystemManager:createDirectory M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P1
+//==== TEST_CRITERIA MR MMINA
+
+test(function () {
+ var retVal;
+
+ add_result_callback(function () {
+ try {
+ tizen.filesystem.deleteDirectory("documents/foo_dir/bar_dir");
+ } catch (err) {
+ }
+ });
+
+ retVal = tizen.filesystem.createDirectory("documents/foo_dir/bar_dir");
+ assert_equals(retVal, undefined, "return value should be undefined");
+}, document.title);
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileSystemManager_createDirectory_InvalidValuesError</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileSystemManager_createDirectory_InvalidValuesError
+//==== LABEL Check if FileSystemManager::createDirectory() method with invalid path throws InvalidValuesError
+//==== SPEC Tizen Web API:IO:Filesystem:FileSystemManager:createDirectory M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P2
+//==== ONLOAD_DELAY 90
+//==== TEST_CRITERIA MC
+
+var t = async_test(document.title), createDirectorySuccess, createDirectoryError;
+
+t.step(function () {
+ createDirectorySuccess = t.step_func(function () {
+ });
+
+ createDirectoryError = t.step_func(function (error) {
+ assert_unreached("createDirectory() error callback invoked: name:" + error.name + "msg:" + error.message);
+ });
+
+ assert_throws(INVALID_VALUES_EXCEPTION, function () {
+ tizen.filesystem.createDirectory("notexist/folder", true, createDirectorySuccess, createDirectoryError);
+ }, "InvalidValuesError should be thrown - invalid path.");
+ t.done();
+});
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileSystemManager_createDirectory_errorCallback_invalid_cb</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileSystemManager_createDirectory_errorCallback_invalid_cb
+//==== LABEL Check if FileSystemManager::createDirectory() method throws exception when errorCallback is invalid
+//==== SPEC Tizen Web API:IO:Filesystem:FileSystemManager:createDirectory M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P2
+//==== ONLOAD_DELAY 90
+//==== TEST_CRITERIA MTCB
+
+var t = async_test(document.title), createDirectorySuccess, invalidCallback;
+
+t.step(function () {
+ createDirectorySuccess = t.step_func(function () {
+ });
+
+ invalidCallback = {
+ onerror: t.step_func(function (error) {
+ assert_unreached("Invalid callback invoked");
+ })
+ };
+
+ assert_throws(TYPE_MISMATCH_EXCEPTION, function () {
+ tizen.filesystem.createDirectory("documents/foo_dir/bar_dir", true, createDirectorySuccess, invalidCallback);
+ }, "given incorrect errorCallback");
+ t.done();
+});
+
+</script>
+</body>
+</html>
\ No newline at end of file
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileSystemManager_createDirectory_errorCallback_invoked_NotFoundError</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileSystemManager_createDirectory_errorCallback_invoked_NotFoundError
+//==== LABEL Check if FileSystemManager::createDirectory() method throws NotFoundError when path not exists
+//==== SPEC Tizen Web API:IO:Filesystem:FileSystemManager:createDirectory M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P2
+//==== ONLOAD_DELAY 90
+//==== TEST_CRITERIA MERRCB
+
+var t = async_test(document.title), createDirectorySuccess, createDirectoryError, retVal;
+
+t.step(function () {
+ createDirectorySuccess = t.step_func(function () {
+ assert_unreached("Should not be invoked createDirectory SuccessCallback");
+ });
+
+ createDirectoryError = t.step_func(function (error) {
+ assert_equals(error.name, "NotFoundError", "expect to throw an NotFoundError exception");
+ t.done();
+ });
+
+ tizen.filesystem.createDirectory("documents/notexist/folder", false, createDirectorySuccess, createDirectoryError);
+});
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileSystemManager_createDirectory_exist</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileSystemManager_createDirectory_exist
+//==== LABEL Check if FileSystemManager::createDirectory() method exists
+//==== SPEC Tizen Web API:IO:Filesystem:FileSystemManager:createDirectory M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P0
+//==== TEST_CRITERIA ME
+
+test(function () {
+ check_method_exists(tizen.filesystem, "createDirectory");
+}, document.title);
+
+</script>
+</body>
+</html>
\ No newline at end of file
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileSystemManager_createDirectory_onerror_TypeMismatch</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileSystemManager_createDirectory_onerror_TypeMismatch
+//==== LABEL Check if FileSystemManager::createDirectory() method throws exception for wrong type of onerror
+//==== SPEC Tizen Web API:IO:Filesystem:FileSystemManager:createDirectory M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P2
+//==== ONLOAD_DELAY 90
+//==== TEST_CRITERIA MC
+
+var t = async_test(document.title), createDirectorySuccess, createDirectoryError,
+ i, conversionTable, exceptionName = "TypeMismatchError";
+
+t.step(function () {
+ createDirectorySuccess = t.step_func(function () {
+ assert_unreached("Should not be invoked to createDirectory Successcallback");
+ });
+
+ conversionTable = getTypeConversionExceptions("functionObject", true);
+ for (i = 0; i < conversionTable.length; i++) {
+ createDirectoryError = conversionTable[i][0];
+
+ assert_throws({name: exceptionName}, function () {
+ tizen.filesystem.createDirectory("documents/foo_dir/bar_dir", true, createDirectorySuccess, createDirectoryError);
+ }, exceptionName + " should be thrown - given incorrect errorCallback.");
+ }
+
+ t.done();
+});
+
+</script>
+</body>
+</html>
\ No newline at end of file
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileSystemManager_createDirectory_onsuccess_TypeMismatch</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileSystemManager_createDirectory_onsuccess_TypeMismatch
+//==== LABEL Check if FileSystemManager::createDirectory() method throws exception for wrong type of onsuccess
+//==== SPEC Tizen Web API:IO:Filesystem:FileSystemManager:createDirectory M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P2
+//==== ONLOAD_DELAY 90
+//==== TEST_CRITERIA MC
+
+var t = async_test(document.title), createDirectorySuccess, createDirectoryError,
+ i, conversionTable, exceptionName = "TypeMismatchError";
+
+t.step(function () {
+ createDirectoryError = t.step_func(function (error) {
+ assert_unreached("createDirectory() error callback invoked: name:" + error.name + "msg:" + error.message);
+ });
+
+ conversionTable = getTypeConversionExceptions("functionObject", true);
+ for (i = 0; i < conversionTable.length; i++) {
+ createDirectorySuccess = conversionTable[i][0];
+
+ assert_throws({name: exceptionName}, function () {
+ tizen.filesystem.createDirectory("documents/foo_dir/bar_dir", true, createDirectorySuccess, createDirectoryError);
+ }, exceptionName + " should be thrown - given incorrect successCallback.");
+ }
+
+ t.done();
+});
+
+</script>
+</body>
+</html>
\ No newline at end of file
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileSystemManager_createDirectory_successCallback_invalid_cb</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileSystemManager_createDirectory_successCallback_invalid_cb
+//==== LABEL Check if FileSystemManager::createDirectory() method throws exception when successCallback is invalid
+//==== SPEC Tizen Web API:IO:Filesystem:FileSystemManager:createDirectory M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P2
+//==== ONLOAD_DELAY 90
+//==== TEST_CRITERIA MTCB
+
+var t = async_test(document.title), invalidCallback, createDirectoryError;
+
+t.step(function () {
+ invalidCallback = {
+ onsuccess: t.step_func(function () {
+ assert_unreached("Invalid callback invoked");
+ })
+ };
+
+ createDirectoryError = t.step_func(function (error) {
+ assert_unreached("createDirectory() error callback invoked: name:" + error.name + "msg:" + error.message);
+ });
+
+ assert_throws(TYPE_MISMATCH_EXCEPTION, function () {
+ tizen.filesystem.createDirectory("documents/foo_dir/bar_dir", true, invalidCallback, createDirectoryError);
+ }, "given incorrect successCallback");
+ t.done();
+});
+
+</script>
+</body>
+</html>
\ No newline at end of file
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileSystemManager_createDirectory_with_errorCallback</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileSystemManager_createDirectory_with_errorCallback
+//==== LABEL Check if FileSystemManager::createDirectory() method works properly with errorCallback
+//==== SPEC Tizen Web API:IO:Filesystem:FileSystemManager:createDirectory M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P1
+//==== ONLOAD_DELAY 90
+//==== TEST_CRITERIA MOA MR MAST
+
+var t = async_test(document.title), createDirectorySuccess, createDirectoryError, retVal;
+
+t.step(function () {
+ add_result_callback(function () {
+ try {
+ tizen.filesystem.deleteDirectory("documents/foo_dir/bar_dir");
+ } catch (err) {
+ }
+ });
+
+ createDirectorySuccess = t.step_func(function () {
+ assert_equals(retVal, undefined, "return value should be undefined");
+ assert_true(tizen.filesystem.pathExists("documents/foo_dir/bar_dir"), "path is not created successfully");
+ t.done();
+ });
+
+ createDirectoryError = t.step_func(function (error) {
+ assert_unreached("createDirectory() error callback invoked: name:" + error.name + "msg:" + error.message);
+ });
+
+ retVal = tizen.filesystem.createDirectory("documents/foo_dir/bar_dir", true, createDirectorySuccess, createDirectoryError);
+});
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileSystemManager_deleteDirectory</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileSystemManager_deleteDirectory
+//==== LABEL Check if FileSystemManager::deleteDirectory() method works properly
+//==== SPEC Tizen Web API:IO:Filesystem:FileSystemManager:deleteDirectory M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P1
+//==== TEST_CRITERIA MR MMINA
+
+test(function () {
+ var retVal;
+
+ tizen.filesystem.createDirectory("documents/foo_dir/bar_dir", true);
+ retVal = tizen.filesystem.deleteDirectory("documents/foo_dir/bar_dir");
+ assert_equals(retVal, undefined, "return value should be undefined");
+}, document.title);
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileSystemManager_deleteDirectory_InvalidValuesError</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileSystemManager_deleteDirectory_InvalidValuesError
+//==== LABEL Check if FileSystemManager::deleteDirectory() method with invalid path throws InvalidValuesError
+//==== SPEC Tizen Web API:IO:Filesystem:FileSystemManager:deleteDirectory M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P2
+//==== TEST_CRITERIA MC
+
+test(function () {
+ assert_throws(INVALID_VALUES_EXCEPTION, function () {
+ tizen.filesystem.deleteDirectory("notexist/folder");
+ }, "InvalidValuesError should be thrown - invalid path.");
+}, document.title);
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileSystemManager_deleteDirectory_errorCallback_invalid_cb</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileSystemManager_deleteDirectory_errorCallback_invalid_cb
+//==== LABEL Check if FileSystemManager::deleteDirectory() method throws exception when errorCallback is invalid
+//==== SPEC Tizen Web API:IO:Filesystem:FileSystemManager:deleteDirectory M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P2
+//==== ONLOAD_DELAY 90
+//==== TEST_CRITERIA MTCB
+
+var t = async_test(document.title), deleteDirectorySuccess, invalidCallback;
+
+t.step(function () {
+ deleteDirectorySuccess = t.step_func(function () {
+ assert_unreached("Should not be invoked deleteDirectory SuccessCallback");
+ });
+
+ invalidCallback = {
+ onerror: t.step_func(function (error) {
+ assert_unreached("Invalid callback invoked");
+ })
+ };
+
+ assert_throws(TYPE_MISMATCH_EXCEPTION, function () {
+ tizen.filesystem.deleteDirectory("documents/foo_dir/bar_dir", true, deleteDirectorySuccess, invalidCallback);
+ }, "given incorrect errorCallback");
+ t.done();
+});
+
+</script>
+</body>
+</html>
\ No newline at end of file
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileSystemManager_deleteDirectory_errorCallback_invoked_NotFoundError</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileSystemManager_deleteDirectory_errorCallback_invoked_NotFoundError
+//==== LABEL Check if FileSystemManager::deleteDirectory() method throws NotFoundError when path not exists
+//==== SPEC Tizen Web API:IO:Filesystem:FileSystemManager:deleteDirectory M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P2
+//==== ONLOAD_DELAY 90
+//==== TEST_CRITERIA MERRCB
+
+var t = async_test(document.title), deleteDirectorySuccess, deleteDirectoryError;
+
+t.step(function () {
+ deleteDirectorySuccess = t.step_func(function () {
+ assert_unreached("Should not be invoked deleteDirectory SuccessCallback");
+ });
+
+ deleteDirectoryError = t.step_func(function (error) {
+ assert_equals(error.name, "NotFoundError", "expect to throw an NotFoundError exception");
+ t.done();
+ });
+
+ tizen.filesystem.deleteDirectory("documents/notexist/folder", false, deleteDirectorySuccess, deleteDirectoryError);
+});
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileSystemManager_deleteDirectory_exist</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileSystemManager_deleteDirectory_exist
+//==== LABEL Check if FileSystemManager::deleteDirectory() method exists
+//==== SPEC Tizen Web API:IO:Filesystem:FileSystemManager:deleteDirectory M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P0
+//==== TEST_CRITERIA ME
+
+test(function () {
+ check_method_exists(tizen.filesystem, "deleteDirectory");
+}, document.title);
+
+</script>
+</body>
+</html>
\ No newline at end of file
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileSystemManager_deleteDirectory_onerror_TypeMismatch</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileSystemManager_deleteDirectory_onerror_TypeMismatch
+//==== LABEL Check if FileSystemManager::deleteDirectory() method throws exception for wrong type of onerror
+//==== SPEC Tizen Web API:IO:Filesystem:FileSystemManager:deleteDirectory M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P2
+//==== ONLOAD_DELAY 90
+//==== TEST_CRITERIA MC
+
+var t = async_test(document.title), deleteDirectorySuccess, deleteDirectoryError,
+ i, conversionTable, exceptionName = "TypeMismatchError";
+
+t.step(function () {
+ deleteDirectorySuccess = t.step_func(function () {
+ assert_unreached("Should not be invoked to deleteDirectory Successcallback");
+ });
+
+ conversionTable = getTypeConversionExceptions("functionObject", true);
+ for (i = 0; i < conversionTable.length; i++) {
+ deleteDirectoryError = conversionTable[i][0];
+
+ assert_throws({name: exceptionName}, function () {
+ tizen.filesystem.deleteDirectory("documents/foo_dir/bar_dir", true, deleteDirectorySuccess, deleteDirectoryError);
+ }, exceptionName + " should be thrown - given incorrect errorCallback.");
+ }
+ t.done();
+});
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileSystemManager_deleteDirectory_onsuccess_TypeMismatch</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileSystemManager_deleteDirectory_onsuccess_TypeMismatch
+//==== LABEL Check if FileSystemManager::deleteDirectory() method throws exception for wrong type of onsuccess
+//==== SPEC Tizen Web API:IO:Filesystem:FileSystemManager:deleteDirectory M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P2
+//==== ONLOAD_DELAY 90
+//==== TEST_CRITERIA MC
+
+var t = async_test(document.title), deleteDirectorySuccess, deleteDirectoryError,
+ i, conversionTable, exceptionName = "TypeMismatchError";
+
+t.step(function () {
+ deleteDirectoryError = t.step_func(function (error) {
+ assert_unreached("deleteDirectory() error callback invoked: name:" + error.name + "msg:" + error.message);
+ });
+
+ conversionTable = getTypeConversionExceptions("functionObject", true);
+ for (i = 0; i < conversionTable.length; i++) {
+ deleteDirectorySuccess = conversionTable[i][0];
+
+ assert_throws({name: exceptionName}, function () {
+ tizen.filesystem.deleteDirectory("documents/foo_dir/bar_dir", true, deleteDirectorySuccess, deleteDirectoryError);
+ }, exceptionName + " should be thrown - given incorrect successCallback.");
+ }
+ t.done();
+});
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileSystemManager_deleteDirectory_successCallback_invalid_cb</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileSystemManager_deleteDirectory_successCallback_invalid_cb
+//==== LABEL Check if FileSystemManager::deleteDirectory() method throws exception when successCallback is invalid
+//==== SPEC Tizen Web API:IO:Filesystem:FileSystemManager:deleteDirectory M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P2
+//==== ONLOAD_DELAY 90
+//==== TEST_CRITERIA MTCB
+
+var t = async_test(document.title), invalidCallback, deleteDirectoryError;
+
+t.step(function () {
+ invalidCallback = {
+ onsuccess: t.step_func(function () {
+ assert_unreached("Invalid callback invoked");
+ })
+ };
+
+ deleteDirectoryError = t.step_func(function (error) {
+ assert_unreached("deleteDirectory() error callback invoked: name:" + error.name + "msg:" + error.message);
+ });
+
+ assert_throws(TYPE_MISMATCH_EXCEPTION, function () {
+ tizen.filesystem.deleteDirectory("documents/foo_dir/bar_dir", true, invalidCallback, deleteDirectoryError);
+ }, "given incorrect successCallback");
+ t.done();
+});
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileSystemManager_deleteDirectory_with_errorCallback</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileSystemManager_deleteDirectory_with_errorCallback
+//==== LABEL Check if FileSystemManager::deleteDirectory() method works properly with errorCallback
+//==== SPEC Tizen Web API:IO:Filesystem:FileSystemManager:deleteDirectory M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P1
+//==== ONLOAD_DELAY 90
+//==== TEST_CRITERIA MOA MR MAST
+
+var t = async_test(document.title), createDirectorySuccess, createDirectoryError, retVal,
+ deleteDirectorySuccess, deleteDirectoryError;
+
+t.step(function () {
+ add_result_callback(function () {
+ try {
+ tizen.filesystem.deleteDirectory("documents/foo_dir");
+ } catch (err) {
+ }
+ });
+
+ createDirectorySuccess = t.step_func(function () {
+ });
+
+ createDirectoryError = t.step_func(function (error) {
+ assert_unreached("createDirectory() error callback invoked: name:" + error.name + "msg:" + error.message);
+ });
+
+ deleteDirectorySuccess = t.step_func(function () {
+ assert_equals(retVal, undefined, "return value should be undefined");
+ assert_false(tizen.filesystem.pathExists("documents/foo_dir/bar_dir"), "Directory is not deleted successfully");
+ t.done();
+ });
+
+ deleteDirectoryError = t.step_func(function (error) {
+ assert_unreached("deleteDirectory() error callback invoked: name:" + error.name + "msg:" + error.message);
+ });
+
+ tizen.filesystem.createDirectory("documents/foo_dir/bar_dir", true, createDirectorySuccess, createDirectoryError);
+ retVal = tizen.filesystem.deleteDirectory("documents/foo_dir/bar_dir", true, deleteDirectorySuccess, deleteDirectoryError);
+});
+
+</script>
+</body>
+</html>
\ No newline at end of file
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileSystemManager_deleteFile</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileSystemManager_deleteFile
+//==== LABEL Check if FileSystemManager::deleteFile() method works properly with makeParents
+//==== SPEC Tizen Web API:IO:Filesystem:FileSystemManager:deleteFile M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P1
+//==== TEST_CRITERIA MR MMINA
+
+test(function () {
+ var retVal;
+
+ tizen.filesystem.openFile("documents/foo", "w");
+ retVal = tizen.filesystem.deleteFile("documents/foo");
+ assert_equals(retVal, undefined, "return value should be undefined");
+}, document.title);
+
+</script>
+</body>
+</html>
\ No newline at end of file
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileSystemManager_deleteFile_InvalidValuesError</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileSystemManager_deleteFile_InvalidValuesError
+//==== LABEL Check if FileSystemManager::deleteFile() method with invalid path throws InvalidValuesError
+//==== SPEC Tizen Web API:IO:Filesystem:FileSystemManager:deleteFile M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P2
+//==== ONLOAD_DELAY 90
+//==== TEST_CRITERIA MC
+
+var t = async_test(document.title), deleteFileSuccess, deleteFileError;
+
+t.step(function () {
+ deleteFileSuccess = t.step_func(function () {
+ });
+
+ deleteFileError = t.step_func(function (error) {
+ assert_unreached("deleteFile() error callback invoked: name:" + error.name + "msg:" + error.message);
+ });
+
+ assert_throws(INVALID_VALUES_EXCEPTION, function () {
+ tizen.filesystem.deleteFile("notexist/folder/file", deleteFileSuccess, deleteFileError);
+ }, "InvalidValuesError should be thrown - invalid path.");
+ t.done();
+});
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileSystemManager_deleteFile_errorCallback_invalid_cb</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileSystemManager_deleteFile_errorCallback_invalid_cb
+//==== LABEL Check if FileSystemManager::deleteFile() method throws exception when errorCallback is invalid
+//==== SPEC Tizen Web API:IO:Filesystem:FileSystemManager:deleteFile M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P2
+//==== ONLOAD_DELAY 90
+//==== TEST_CRITERIA MTCB
+
+var t = async_test(document.title), deleteFileSuccess, invalidCallback;
+
+t.step(function () {
+ add_result_callback(function () {
+ try {
+ tizen.filesystem.deleteFile("documents/foo");
+ } catch (err) {
+ }
+ });
+
+ deleteFileSuccess = t.step_func(function () {
+ assert_unreached("Should not be invoked deleteFile SuccessCallback");
+ });
+
+ invalidCallback = {
+ onerror: t.step_func(function (error) {
+ assert_unreached("Invalid callback invoked");
+ })
+ };
+
+ tizen.filesystem.openFile("documents/foo", "w");
+ assert_throws(TYPE_MISMATCH_EXCEPTION, function () {
+ tizen.filesystem.deleteFile("documents/foo", deleteFileSuccess, invalidCallback);
+ }, "given incorrect errorCallback");
+ t.done();
+});
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileSystemManager_deleteFile_errorCallback_invoked_NotFoundError</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileSystemManager_deleteFile_errorCallback_invoked_NotFoundError
+//==== LABEL Check if FileSystemManager::deleteFile() method throws NotFoundError when file not exists
+//==== SPEC Tizen Web API:IO:Filesystem:FileSystemManager:deleteFile M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P2
+//==== ONLOAD_DELAY 90
+//==== TEST_CRITERIA MERRCB
+
+var t = async_test(document.title), deleteFileSuccess, deleteFileError;
+
+t.step(function () {
+ deleteFileSuccess = t.step_func(function () {
+ assert_unreached("Should not be invoked deleteFile SuccessCallback");
+ });
+
+ deleteFileError = t.step_func(function (error) {
+ assert_equals(error.name, "NotFoundError", "expect to throw an NotFoundError exception");
+ t.done();
+ });
+
+ tizen.filesystem.deleteFile("documents/not_exist_file", deleteFileSuccess, deleteFileError);
+});
+
+</script>
+</body>
+</html>
\ No newline at end of file
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileSystemManager_deleteFile_exist</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileSystemManager_deleteFile_exist
+//==== LABEL Check if FileSystemManager::deleteFile() method exists
+//==== SPEC Tizen Web API:IO:Filesystem:FileSystemManager:deleteFile M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P0
+//==== TEST_CRITERIA ME
+
+test(function () {
+ check_method_exists(tizen.filesystem, "deleteFile");
+}, document.title);
+
+</script>
+</body>
+</html>
\ No newline at end of file
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileSystemManager_deleteFile_onerror_TypeMismatch</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileSystemManager_deleteFile_onerror_TypeMismatch
+//==== LABEL Check if FileSystemManager::deleteFile() method throws exception for wrong type of onerror
+//==== SPEC Tizen Web API:IO:Filesystem:FileSystemManager:deleteFile M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P2
+//==== ONLOAD_DELAY 90
+//==== TEST_CRITERIA MC
+
+var t = async_test(document.title), deleteFileSuccess, deleteFileError,
+ i, conversionTable, exceptionName = "TypeMismatchError";
+
+t.step(function () {
+ deleteFileSuccess = t.step_func(function () {
+ assert_unreached("Should not be invoked to deleteFile Successcallback");
+ });
+
+ conversionTable = getTypeConversionExceptions("functionObject", true);
+ for (i = 0; i < conversionTable.length; i++) {
+ deleteFileError = conversionTable[i][0];
+
+ assert_throws({name: exceptionName}, function () {
+ tizen.filesystem.deleteFile("documents/foo", deleteFileSuccess, deleteFileError);
+ }, exceptionName + " should be thrown - given incorrect errorCallback.");
+ }
+ t.done();
+});
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileSystemManager_deleteFile_with_errorCallback</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileSystemManager_deleteFile_with_errorCallback
+//==== LABEL Check if FileSystemManager::deleteFile() method throws exception for wrong type of onsuccess
+//==== SPEC Tizen Web API:IO:Filesystem:FileSystemManager:deleteFile M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P2
+//==== ONLOAD_DELAY 90
+//==== TEST_CRITERIA MC
+
+var t = async_test(document.title), deleteFileSuccess, deleteFileError,
+ i, conversionTable, exceptionName = "TypeMismatchError";
+
+t.step(function () {
+ deleteFileError = t.step_func(function (error) {
+ assert_unreached("deleteFile() error callback invoked: name:" + error.name + "msg:" + error.message);
+ });
+
+ conversionTable = getTypeConversionExceptions("functionObject", true);
+ for (i = 0; i < conversionTable.length; i++) {
+ deleteFileSuccess = conversionTable[i][0];
+
+ assert_throws({name: exceptionName}, function () {
+ tizen.filesystem.deleteFile("documents/foo", deleteFileSuccess, deleteFileError);
+ }, exceptionName + " should be thrown - given incorrect successCallback.");
+ }
+ t.done();
+});
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileSystemManager_deleteFile_successCallback_invalid_cb</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileSystemManager_deleteFile_successCallback_invalid_cb
+//==== LABEL Check if FileSystemManager::deleteFile() method throws exception when successCallback is invalid
+//==== SPEC Tizen Web API:IO:Filesystem:FileSystemManager:deleteFile M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P2
+//==== ONLOAD_DELAY 90
+//==== TEST_CRITERIA MTCB
+
+var t = async_test(document.title), invalidCallback, deleteFileError;
+
+t.step(function () {
+ add_result_callback(function () {
+ try {
+ tizen.filesystem.deleteFile("documents/foo");
+ } catch (err) {
+ }
+ });
+
+ invalidCallback = {
+ onsuccess: t.step_func(function () {
+ assert_unreached("Invalid callback invoked");
+ })
+ };
+
+ deleteFileError = t.step_func(function (error) {
+ assert_unreached("deleteFile() error callback invoked: name:" + error.name + "msg:" + error.message);
+ });
+
+ tizen.filesystem.openFile("documents/foo", "w");
+ assert_throws(TYPE_MISMATCH_EXCEPTION, function () {
+ tizen.filesystem.deleteFile("documents/foo", invalidCallback, deleteFileError);
+ }, "given incorrect successCallback");
+ t.done();
+});
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileSystemManager_deleteFile_with_errorCallback</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileSystemManager_deleteFile_with_errorCallback
+//==== LABEL Check if FileSystemManager::deleteFile() method works properly with errorCallback
+//==== SPEC Tizen Web API:IO:Filesystem:FileSystemManager:deleteFile M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P1
+//==== ONLOAD_DELAY 90
+//==== TEST_CRITERIA MOA MR MAST
+
+var t = async_test(document.title), deleteFileSuccess, deleteFileError, retVal;
+
+t.step(function () {
+ deleteFileSuccess = t.step_func(function () {
+ assert_equals(retVal, undefined, "return value should be undefined");
+ assert_false(tizen.filesystem.pathExists("documents/foo"), "file is not deleted successfully");
+ t.done();
+ });
+
+ deleteFileError = t.step_func(function (error) {
+ assert_unreached("deleteFile() error callback invoked: name:" + error.name + "msg:" + error.message);
+ });
+
+ tizen.filesystem.openFile("documents/foo", "w");
+ retVal = tizen.filesystem.deleteFile("documents/foo", deleteFileSuccess, deleteFileError);
+});
+
+</script>
+</body>
+</html>
\ No newline at end of file
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileSystemManager_getDirName</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileSystemManager_getDirName
+//==== LABEL Check if FileSystemManager::getDirName() method works properly
+//==== SPEC Tizen Web API:IO:Filesystem:FileSystemManager:getDirName M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P1
+//==== TEST_CRITERIA MR
+
+test(function () {
+ var retVal;
+
+ retVal = tizen.filesystem.getDirName("/home/owner/media/Documents");
+ assert_type(retVal, "string", "Type of return value should be of string.");
+ assert_equals(retVal, "/home/owner/media", "The directory name is not right.");
+}, document.title);
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileSystemManager_getDirName_exist</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileSystemManager_getDirName_exist
+//==== LABEL Check if FileSystemManager::getDirName() method exists
+//==== SPEC Tizen Web API:IO:Filesystem:FileSystemManager:getDirName M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P0
+//==== TEST_CRITERIA ME
+
+test(function () {
+ check_method_exists(tizen.filesystem, "getDirName");
+}, document.title);
+
+</script>
+</body>
+</html>
\ No newline at end of file
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileSystemManager_isDirectory</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileSystemManager_isDirectory
+//==== LABEL Check if FileSystemManager::isDirectory() method works properly
+//==== SPEC Tizen Web API:IO:Filesystem:FileSystemManager:isDirectory M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P1
+//==== TEST_CRITERIA MR
+
+var t = async_test(document.title), createDirectorySuccess, createDirectoryError, retVal;
+
+t.step(function () {
+ add_result_callback(function () {
+ try {
+ tizen.filesystem.deleteDirectory("documents/foo_dir");
+ } catch (err) {
+ }
+ });
+
+ createDirectorySuccess = t.step_func(function () {
+ retVal = tizen.filesystem.isDirectory("documents/foo_dir");
+ assert_type(retVal, "boolean", "Type of return value should be of boolean.");
+ assert_true(retVal, "The path does not point to a directory.");
+ t.done();
+ });
+
+ createDirectoryError = t.step_func(function (error) {
+ assert_unreached("createDirectory() error callback invoked: name:" + error.name + "msg:" + error.message);
+ });
+
+ tizen.filesystem.createDirectory("documents/foo_dir", true, createDirectorySuccess, createDirectoryError);
+});
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileSystemManager_isDirectory_InvalidValuesError</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileSystemManager_isDirectory_InvalidValuesError
+//==== LABEL Check if FileSystemManager::isDirectory() method with invalid path throws InvalidValuesError
+//==== SPEC Tizen Web API:IO:Filesystem:FileSystemManager:isDirectory M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P2
+//==== TEST_CRITERIA MC
+
+test(function () {
+ assert_throws(INVALID_VALUES_EXCEPTION, function () {
+ tizen.filesystem.isDirectory("notexist");
+ }, "InvalidValuesError should be thrown - invalid path.");
+}, document.title);
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileSystemManager_isDirectory_NotFoundError</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileSystemManager_isDirectory_NotFoundError
+//==== LABEL Check if FileSystemManager::isDirectory() method throws NotFoundError when path not exists
+//==== SPEC Tizen Web API:IO:Filesystem:FileSystemManager:isDirectory M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P2
+//==== TEST_CRITERIA MC
+
+test(function () {
+ assert_throws(NOT_FOUND_EXCEPTION, function () {
+ tizen.filesystem.isDirectory("documents/notexist");
+ }, "NotFoundError should be thrown - path not exists.");
+}, document.title);
+
+</script>
+</body>
+</html>
\ No newline at end of file
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileSystemManager_isDirectory_exist</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileSystemManager_isDirectory_exist
+//==== LABEL Check if FileSystemManager::isDirectory() method exists
+//==== SPEC Tizen Web API:IO:Filesystem:FileSystemManager:isDirectory M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P0
+//==== TEST_CRITERIA ME
+
+test(function () {
+ check_method_exists(tizen.filesystem, "isDirectory");
+}, document.title);
+
+</script>
+</body>
+</html>
\ No newline at end of file
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileSystemManager_isDirectory_misarg</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileSystemManager_isDirectory_misarg
+//==== LABEL Check if FileSystemManager::isDirectory() method with missing mandatory argument throws exception
+//==== SPEC Tizen Web API:IO:Filesystem:FileSystemManager:isDirectory M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P2
+//==== TEST_CRITERIA MMA
+
+test(function () {
+ assert_throws(INVALID_VALUES_EXCEPTION, function () {
+ tizen.filesystem.isDirectory();
+ }, "InvalidValuesError should be thrown.");
+}, document.title);
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileSystemManager_isFile</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileSystemManager_isFile
+//==== LABEL Check if FileSystemManager::isFile() method works properly
+//==== SPEC Tizen Web API:IO:Filesystem:FileSystemManager:isFile M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P1
+//==== TEST_CRITERIA MR
+
+test(function () {
+ var retVal;
+
+ add_result_callback(function () {
+ try {
+ tizen.filesystem.deleteFile("documents/foo_file");
+ } catch (err) {
+ }
+ });
+
+ tizen.filesystem.openFile("documents/foo_file", "w");
+ retVal = tizen.filesystem.isFile("documents/foo_file");
+ assert_type(retVal, "boolean", "Type of return value should be of boolean.");
+ assert_true(retVal, "The path does not point to a file.");
+}, document.title);
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileSystemManager_isFile_InvalidValuesError</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileSystemManager_isFile_InvalidValuesError
+//==== LABEL Check if FileSystemManager::isFile() method with invalid path throws InvalidValuesError
+//==== SPEC Tizen Web API:IO:Filesystem:FileSystemManager:isFile M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P2
+//==== TEST_CRITERIA MC
+
+test(function () {
+ assert_throws(INVALID_VALUES_EXCEPTION, function () {
+ tizen.filesystem.isFile("notexist/folder/file");
+ }, "InvalidValuesError should be thrown - invalid path.");
+}, document.title);
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileSystemManager_isFile_NotFoundError</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileSystemManager_isFile_NotFoundError
+//==== LABEL Check if FileSystemManager::isFile() method throws NotFoundError when file not exists
+//==== SPEC Tizen Web API:IO:Filesystem:FileSystemManager:isFile M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P2
+//==== TEST_CRITERIA MC
+
+test(function () {
+ assert_throws(NOT_FOUND_EXCEPTION, function () {
+ tizen.filesystem.isFile("documents/notexist");
+ }, "NotFoundError should be thrown - file not exists.");
+}, document.title);
+
+</script>
+</body>
+</html>
\ No newline at end of file
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileSystemManager_isFile_exist</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileSystemManager_isFile_exist
+//==== LABEL Check if FileSystemManager::isFile() method exists
+//==== SPEC Tizen Web API:IO:Filesystem:FileSystemManager:isFile M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P0
+//==== TEST_CRITERIA ME
+
+test(function () {
+ check_method_exists(tizen.filesystem, "isFile");
+}, document.title);
+
+</script>
+</body>
+</html>
\ No newline at end of file
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileSystemManager_isFile_misarg</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileSystemManager_isFile_misarg
+//==== LABEL Check if FileSystemManager::isFile() method with missing mandatory argument throws exception
+//==== SPEC Tizen Web API:IO:Filesystem:FileSystemManager:isFile M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P2
+//==== TEST_CRITERIA MMA
+
+test(function () {
+ assert_throws(INVALID_VALUES_EXCEPTION, function () {
+ tizen.filesystem.isFile();
+ }, "InvalidValuesError should be thrown.");
+}, document.title);
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileSystemManager_listDirectory</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileSystemManager_listDirectory
+//==== LABEL Check if FileSystemManager::listDirectory() method works properly
+//==== SPEC Tizen Web API:IO:Filesystem:FileSystemManager:listDirectory M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P1
+//==== ONLOAD_DELAY 90
+//==== TEST_CRITERIA MR MMINA
+
+var t = async_test(document.title), listDirectorySuccess, retVal;
+
+t.step(function () {
+ add_result_callback(function () {
+ try {
+ tizen.filesystem.deleteDirectory("documents/foo_dir");
+ } catch (err) {
+ }
+ });
+
+ listDirectorySuccess = t.step_func(function (files) {
+ assert_greater_than_equal(files.length, 1, "Successfully to list directory content");
+ t.done();
+ });
+
+ tizen.filesystem.createDirectory("documents/foo_dir");
+ retVal = tizen.filesystem.listDirectory("documents/", listDirectorySuccess);
+ assert_equals(retVal, undefined, "return value should be undefined");
+});
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileSystemManager_listDirectory_InvalidValuesError</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileSystemManager_listDirectory_InvalidValuesError
+//==== LABEL Check if FileSystemManager::listDirectory() method with invalid path throws InvalidValuesError
+//==== SPEC Tizen Web API:IO:Filesystem:FileSystemManager:listDirectory M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P2
+//==== ONLOAD_DELAY 90
+//==== TEST_CRITERIA MC
+
+var t = async_test(document.title), listDirectorySuccess, listDirectoryError;
+
+t.step(function () {
+ listDirectorySuccess = t.step_func(function () {
+ });
+
+ listDirectoryError = t.step_func(function (error) {
+ assert_unreached("listDirectory() error callback invoked: name:" + error.name + "msg:" + error.message);
+ });
+
+ assert_throws(INVALID_VALUES_EXCEPTION, function () {
+ tizen.filesystem.listDirectory("notexist/folder", listDirectorySuccess, listDirectoryError);
+ }, "InvalidValuesError should be thrown - invalid path.");
+ t.done();
+});
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileSystemManager_listDirectory_errorCallback_invalid_cb</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileSystemManager_listDirectory_errorCallback_invalid_cb
+//==== LABEL Check if FileSystemManager::listDirectory() method throws exception when errorCallback is invalid
+//==== SPEC Tizen Web API:IO:Filesystem:FileSystemManager:listDirectory M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P2
+//==== ONLOAD_DELAY 90
+//==== TEST_CRITERIA MTCB
+
+var t = async_test(document.title), listDirectorySuccess, invalidCallback;
+
+t.step(function () {
+ add_result_callback(function () {
+ try {
+ tizen.filesystem.deleteDirectory("documents/foo_dir");
+ } catch (err) {
+ }
+ });
+
+ listDirectorySuccess = t.step_func(function () {
+ assert_unreached("Should not be invoked listDirectory SuccessCallback");
+ });
+
+ invalidCallback = {
+ onerror: t.step_func(function (error) {
+ assert_unreached("Invalid callback invoked");
+ })
+ };
+
+
+ tizen.filesystem.createDirectory("documents/foo_dir");
+
+ assert_throws(TYPE_MISMATCH_EXCEPTION, function () {
+ tizen.filesystem.listDirectory("documents/", listDirectorySuccess, invalidCallback);
+ }, "given incorrect errorCallback");
+ t.done();
+});
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileSystemManager_listDirectory_errorCallback_invoked_NotFoundError</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileSystemManager_listDirectory_errorCallback_invoked_NotFoundError
+//==== LABEL Check if FileSystemManager::listDirectory() method throws NotFoundError when path not exists
+//==== SPEC Tizen Web API:IO:Filesystem:FileSystemManager:listDirectory M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P2
+//==== ONLOAD_DELAY 90
+//==== TEST_CRITERIA MERRCB
+
+var t = async_test(document.title), listDirectorySuccess, listDirectoryError;
+
+t.step(function () {
+ listDirectorySuccess = t.step_func(function () {
+ assert_unreached("Should not be invoked listDirectory SuccessCallback");
+ });
+
+ listDirectoryError = t.step_func(function (error) {
+ assert_equals(error.name, "NotFoundError", "expect to throw an NotFoundError exception");
+ t.done();
+ });
+
+ tizen.filesystem.listDirectory("documents/wrong_dir", listDirectorySuccess, listDirectoryError);
+});
+
+</script>
+</body>
+</html>
\ No newline at end of file
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileSystemManager_listDirectory_exist</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileSystemManager_listDirectory_exist
+//==== LABEL Check if FileSystemManager::listDirectory() method exists
+//==== SPEC Tizen Web API:IO:Filesystem:FileSystemManager:listDirectory M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P0
+//==== TEST_CRITERIA ME
+
+test(function () {
+ check_method_exists(tizen.filesystem, "listDirectory");
+}, document.title);
+
+</script>
+</body>
+</html>
\ No newline at end of file
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileSystemManager_listDirectory_misarg</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileSystemManager_listDirectory_misarg
+//==== LABEL Check if FileSystemManager::listDirectory() method with missing mandatory argument throws exception
+//==== SPEC Tizen Web API:IO:Filesystem:FileSystemManager:listDirectory M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P2
+//==== TEST_CRITERIA MMA
+
+test(function () {
+ assert_throws(INVALID_VALUES_EXCEPTION, function () {
+ tizen.filesystem.listDirectory();
+ }, "InvalidValuesError should be thrown.");
+}, document.title);
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileSystemManager_listDirectory_onerror_TypeMismatch</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileSystemManager_listDirectory_onerror_TypeMismatch
+//==== LABEL Check if FileSystemManager::listDirectory() method throws exception for wrong type of onerror
+//==== SPEC Tizen Web API:IO:Filesystem:FileSystemManager:listDirectory M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P2
+//==== ONLOAD_DELAY 90
+//==== TEST_CRITERIA MC
+
+var t = async_test(document.title), listDirectorySuccess, listDirectoryError,
+ i, conversionTable, exceptionName = "TypeMismatchError";
+
+t.step(function () {
+ add_result_callback(function () {
+ try {
+ tizen.filesystem.deleteDirectory("documents/foo_dir");
+ } catch (err) {
+ }
+ });
+
+ listDirectorySuccess = t.step_func(function (files) {
+ assert_unreached("Should not be invoked to listDirectory Successcallback");
+ });
+
+ tizen.filesystem.createDirectory("documents/foo_dir");
+ conversionTable = getTypeConversionExceptions("functionObject", true);
+ for (i = 0; i < conversionTable.length; i++) {
+ listDirectoryError = conversionTable[i][0];
+
+ assert_throws({name: exceptionName}, function () {
+ tizen.filesystem.listDirectory("documents/", listDirectorySuccess, listDirectoryError);
+ }, exceptionName + " should be thrown - given incorrect errorCallback.");
+ }
+ t.done();
+});
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileSystemManager_listDirectory_onsuccess_TypeMismatch</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileSystemManager_listDirectory_onsuccess_TypeMismatch
+//==== LABEL Check if FileSystemManager::listDirectory() method throws exception for wrong type of onsuccess
+//==== SPEC Tizen Web API:IO:Filesystem:FileSystemManager:listDirectory M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P2
+//==== ONLOAD_DELAY 90
+//==== TEST_CRITERIA MC
+
+var t = async_test(document.title), listDirectorySuccess, listDirectoryError,
+ i, conversionTable, exceptionName = "TypeMismatchError";
+
+t.step(function () {
+ add_result_callback(function () {
+ try {
+ tizen.filesystem.deleteDirectory("documents/foo_dir");
+ } catch (err) {
+ }
+ });
+
+ listDirectoryError = t.step_func(function (error) {
+ assert_unreached("listDirectory() error callback invoked: name:" + error.name + "msg:" + error.message);
+ });
+
+ tizen.filesystem.createDirectory("documents/foo_dir");
+ conversionTable = getTypeConversionExceptions("functionObject", true);
+ for (i = 0; i < conversionTable.length; i++) {
+ listDirectorySuccess = conversionTable[i][0];
+
+ assert_throws({name: exceptionName}, function () {
+ tizen.filesystem.listDirectory("documents/", listDirectorySuccess, listDirectoryError);
+ }, exceptionName + " should be thrown - given incorrect successCallback.");
+ }
+ t.done();
+});
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileSystemManager_listDirectory_successCallback_invalid_cb</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileSystemManager_listDirectory_successCallback_invalid_cb
+//==== LABEL Check if FileSystemManager::listDirectory() method throws exception when successCallback is invalid
+//==== SPEC Tizen Web API:IO:Filesystem:FileSystemManager:listDirectory M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P2
+//==== ONLOAD_DELAY 90
+//==== TEST_CRITERIA MTCB
+
+var t = async_test(document.title), invalidCallback, listDirectoryError;
+
+t.step(function () {
+ add_result_callback(function () {
+ try {
+ tizen.filesystem.deleteDirectory("documents/foo_dir");
+ } catch (err) {
+ }
+ });
+
+ invalidCallback = {
+ onsuccess: t.step_func(function () {
+ assert_unreached("Invalid callback invoked");
+ })
+ };
+
+ listDirectoryError = t.step_func(function (error) {
+ assert_unreached("listDirectory() error callback invoked: name:" + error.name + "msg:" + error.message);
+ });
+
+ tizen.filesystem.createDirectory("documents/foo_dir");
+
+ assert_throws(TYPE_MISMATCH_EXCEPTION, function () {
+ tizen.filesystem.listDirectory("documents/", invalidCallback, listDirectoryError);
+ }, "given incorrect successCallback");
+ t.done();
+});
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileSystemManager_listDirectory_with_filter</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileSystemManager_listDirectory_with_filter
+//==== LABEL Check if FileSystemManager::listDirectory() method works properly with filter
+//==== SPEC Tizen Web API:IO:Filesystem:FileSystemManager:listDirectory M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P1
+//==== ONLOAD_DELAY 90
+//==== TEST_CRITERIA MOA MR
+
+var t = async_test(document.title), listDirectorySuccess, listDirectoryError, retVal;
+
+t.step(function () {
+ add_result_callback(function () {
+ try {
+ tizen.filesystem.deleteDirectory("documents/foo_dir");
+ } catch (err) {
+ }
+ });
+
+ listDirectorySuccess = t.step_func(function (files) {
+ assert_greater_than_equal(files.length, 1, "Not successfully list directory content");
+ t.done();
+ });
+
+ listDirectoryError = t.step_func(function (error) {
+ assert_unreached("listDirectory() error callback invoked: name:" + error.name + "msg:" + error.message);
+ });
+
+ tizen.filesystem.createDirectory("documents/foo_dir");
+ retVal = tizen.filesystem.listDirectory("documents/", listDirectorySuccess, listDirectoryError, {name: "foo_%"});
+ assert_equals(retVal, undefined, "return value should be undefined");
+});
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileSystemManager_maxNameLength_attribute</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileSystemManager_maxNameLength_attribute
+//==== LABEL Check if attribute maxNameLength of FileSystemManager exists, has type long and is readonly
+//==== SPEC Tizen Web API:IO:Filesystem:FileSystemManager:maxNameLength A
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P1
+//==== TEST_CRITERIA AE AT ARO
+
+test(function () {
+ check_readonly(tizen.filesystem, "maxNameLength", tizen.filesystem.maxNameLength, "long", tizen.filesystem.maxNameLength + 5);
+}, document.title);
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileSystemManager_moveDirectory</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileSystemManager_moveDirectory
+//==== LABEL Check if FileSystemManager::moveDirectory() method works properly
+//==== SPEC Tizen Web API:IO:Filesystem:FileSystemManager:moveDirectory M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P1
+//==== TEST_CRITERIA MR MMINA MAST
+
+test(function () {
+ var retVal;
+
+ add_result_callback(function () {
+ try {
+ tizen.filesystem.deleteDirectory("documents/foo_dir", true);
+ tizen.filesystem.deleteDirectory("documents/bar_dir", true);
+ } catch (err) {
+ }
+ });
+
+ tizen.filesystem.createDirectory("documents/foo_dir");
+ tizen.filesystem.createDirectory("documents/bar_dir");
+ retVal = tizen.filesystem.moveDirectory("documents/foo_dir", "documents/bar_dir");
+ assert_equals(retVal, undefined, "return value should be undefined");
+ assert_true(!tizen.filesystem.pathExists("documents/foo_dir") && tizen.filesystem.pathExists("documents/bar_dir/foo_dir"),
+ "directory is moved to the destination path successfully");
+}, document.title);
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileSystemManager_moveDirectory_InvalidValuesError</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileSystemManager_moveDirectory_InvalidValuesError
+//==== LABEL Check if FileSystemManager::moveDirectory() method with invalid path throws InvalidValuesError
+//==== SPEC Tizen Web API:IO:Filesystem:FileSystemManager:moveDirectory M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P2
+//==== ONLOAD_DELAY 90
+//==== TEST_CRITERIA MC
+
+var t = async_test(document.title), moveDirectorySuccess, moveDirectoryError;
+
+t.step(function () {
+ moveDirectorySuccess = t.step_func(function () {
+ });
+
+ moveDirectoryError = t.step_func(function (error) {
+ assert_unreached("moveDirectory() error callback invoked: name:" + error.name + "msg:" + error.message);
+ });
+
+ assert_throws(INVALID_VALUES_EXCEPTION, function () {
+ tizen.filesystem.moveDirectory("notexist/folder", "documents/bar_dir", false, moveDirectorySuccess, moveDirectoryError);
+ }, "InvalidValuesError should be thrown - invalid path.");
+ t.done();
+});
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileSystemManager_moveDirectory_errorCallback_invalid_cb</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileSystemManager_moveDirectory_errorCallback_invalid_cb
+//==== LABEL Check if FileSystemManager::moveDirectory() method throws exception when errorCallback is invalid
+//==== SPEC Tizen Web API:IO:Filesystem:FileSystemManager:moveDirectory M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P2
+//==== ONLOAD_DELAY 90
+//==== TEST_CRITERIA MTCB
+
+var t = async_test(document.title), moveDirectorySuccess, invalidCallback;
+
+t.step(function () {
+ add_result_callback(function () {
+ try {
+ tizen.filesystem.deleteDirectory("documents/foo_dir", true);
+ tizen.filesystem.deleteDirectory("documents/bar_dir", true);
+ } catch (err) {
+ }
+ });
+
+ moveDirectorySuccess = t.step_func(function () {
+ assert_unreached("Should not be invoked moveDirectory SuccessCallback");
+ });
+
+ invalidCallback = {
+ onerror: t.step_func(function (error) {
+ assert_unreached("Invalid callback invoked");
+ })
+ };
+
+ tizen.filesystem.createDirectory("documents/foo_dir");
+ tizen.filesystem.createDirectory("documents/bar_dir");
+
+ assert_throws(TYPE_MISMATCH_EXCEPTION, function () {
+ tizen.filesystem.moveDirectory("documents/foo_dir", "documents/bar_dir", false, moveDirectorySuccess, invalidCallback);
+ }, "given incorrect errorCallback");
+ t.done();
+});
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileSystemManager_moveDirectory_errorCallback_invoked_NotFoundError</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileSystemManager_moveDirectory_errorCallback_invoked_NotFoundError
+//==== LABEL Check if FileSystemManager::moveDirectory() method throws NotFoundError when path not exists
+//==== SPEC Tizen Web API:IO:Filesystem:FileSystemManager:moveDirectory M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P2
+//==== ONLOAD_DELAY 90
+//==== TEST_CRITERIA MERRCB
+
+var t = async_test(document.title), moveDirectorySuccess, moveDirectoryError;
+
+t.step(function () {
+ moveDirectorySuccess = t.step_func(function () {
+ assert_unreached("Should not be invoked moveDirectory SuccessCallback");
+ });
+
+ moveDirectoryError = t.step_func(function (error) {
+ assert_equals(error.name, "NotFoundError", "expect to throw an NotFoundError exception");
+ t.done();
+ });
+
+ tizen.filesystem.moveDirectory("documents/wrong_dir", "documents/bar_dir", false, moveDirectorySuccess, moveDirectoryError);
+});
+
+</script>
+</body>
+</html>
\ No newline at end of file
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileSystemManager_moveDirectory_exist</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileSystemManager_moveDirectory_exist
+//==== LABEL Check if FileSystemManager::moveDirectory() method exists
+//==== SPEC Tizen Web API:IO:Filesystem:FileSystemManager:moveDirectory M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P0
+//==== TEST_CRITERIA ME
+
+test(function () {
+ check_method_exists(tizen.filesystem, "moveDirectory");
+}, document.title);
+
+</script>
+</body>
+</html>
\ No newline at end of file
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileSystemManager_moveDirectory_misarg</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileSystemManager_moveDirectory_misarg
+//==== LABEL Check if FileSystemManager::moveDirectory() method with missing mandatory argument throws exception
+//==== SPEC Tizen Web API:IO:Filesystem:FileSystemManager:moveDirectory M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P2
+//==== TEST_CRITERIA MMA
+
+test(function () {
+ assert_throws(INVALID_VALUES_EXCEPTION, function () {
+ tizen.filesystem.moveDirectory();
+ }, "InvalidValuesError should be thrown.");
+}, document.title);
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileSystemManager_moveDirectory_onerror_TypeMismatch</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileSystemManager_moveDirectory_onerror_TypeMismatch
+//==== LABEL Check if FileSystemManager::moveDirectory() method throws exception for wrong type of onerror
+//==== SPEC Tizen Web API:IO:Filesystem:FileSystemManager:moveDirectory M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P2
+//==== ONLOAD_DELAY 90
+//==== TEST_CRITERIA MC
+
+var t = async_test(document.title), moveDirectorySuccess, moveDirectoryError,
+ i, conversionTable, exceptionName = "TypeMismatchError";
+
+t.step(function () {
+ add_result_callback(function () {
+ try {
+ tizen.filesystem.deleteDirectory("documents/foo_dir", true);
+ tizen.filesystem.deleteDirectory("documents/bar_dir", true);
+ } catch (err) {
+ }
+ });
+
+ moveDirectorySuccess = t.step_func(function () {
+ assert_unreached("Should not be invoked to moveDirectory Successcallback");
+ });
+
+ tizen.filesystem.createDirectory("documents/foo_dir");
+ tizen.filesystem.createDirectory("documents/bar_dir");
+
+ conversionTable = getTypeConversionExceptions("functionObject", true);
+ for (i = 0; i < conversionTable.length; i++) {
+ moveDirectoryError = conversionTable[i][0];
+
+ assert_throws({name: exceptionName}, function () {
+ tizen.filesystem.moveDirectory("documents/foo_dir", "documents/bar_dir", false, moveDirectorySuccess, moveDirectoryError);
+ }, exceptionName + " should be thrown - given incorrect errorCallback.");
+ }
+ t.done();
+});
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileSystemManager_moveDirectory_onsuccess_TypeMismatch</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileSystemManager_moveDirectory_onsuccess_TypeMismatch
+//==== LABEL Check if FileSystemManager::moveDirectory() method throws exception for wrong type of onsuccess
+//==== SPEC Tizen Web API:IO:Filesystem:FileSystemManager:moveDirectory M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P2
+//==== ONLOAD_DELAY 90
+//==== TEST_CRITERIA MC
+
+var t = async_test(document.title), moveDirectorySuccess, moveDirectoryError,
+ i, conversionTable, exceptionName = "TypeMismatchError";
+
+t.step(function () {
+ add_result_callback(function () {
+ try {
+ tizen.filesystem.deleteDirectory("documents/foo_dir", true);
+ tizen.filesystem.deleteDirectory("documents/bar_dir", true);
+ } catch (err) {
+ }
+ });
+
+ moveDirectoryError = t.step_func(function (error) {
+ assert_unreached("moveDirectory() error callback invoked: name:" + error.name + "msg:" + error.message);
+ });
+
+ tizen.filesystem.createDirectory("documents/foo_dir");
+ tizen.filesystem.createDirectory("documents/bar_dir");
+
+ conversionTable = getTypeConversionExceptions("functionObject", true);
+ for (i = 0; i < conversionTable.length; i++) {
+ moveDirectorySuccess = conversionTable[i][0];
+
+ assert_throws({name: exceptionName}, function () {
+ tizen.filesystem.moveDirectory("documents/foo_dir", "documents/bar_dir", false, moveDirectorySuccess, moveDirectoryError);
+ }, exceptionName + " should be thrown - given incorrect successCallback.");
+ }
+ t.done();
+});
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileSystemManager_moveDirectory_successCallback_invalid_cb</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileSystemManager_moveDirectory_successCallback_invalid_cb
+//==== LABEL Check if FileSystemManager::moveDirectory() method throws exception when successCallback is invalid
+//==== SPEC Tizen Web API:IO:Filesystem:FileSystemManager:moveDirectory M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P2
+//==== ONLOAD_DELAY 90
+//==== TEST_CRITERIA MTCB
+
+var t = async_test(document.title), invalidCallback, moveDirectoryError;
+
+t.step(function () {
+ add_result_callback(function () {
+ try {
+ tizen.filesystem.deleteDirectory("documents/foo_dir", true);
+ tizen.filesystem.deleteDirectory("documents/bar_dir", true);
+ } catch (err) {
+ }
+ });
+
+ invalidCallback = {
+ onsuccess: t.step_func(function () {
+ assert_unreached("Invalid callback invoked");
+ })
+ };
+
+ moveDirectoryError = t.step_func(function (error) {
+ assert_unreached("moveDirectory() error callback invoked: name:" + error.name + "msg:" + error.message);
+ });
+
+ tizen.filesystem.createDirectory("documents/foo_dir");
+ tizen.filesystem.createDirectory("documents/bar_dir");
+
+ assert_throws(TYPE_MISMATCH_EXCEPTION, function () {
+ tizen.filesystem.moveDirectory("documents/foo_dir", "documents/bar_dir", false, invalidCallback, moveDirectoryError);
+ }, "given incorrect successCallback");
+ t.done();
+});
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileSystemManager_moveDirectory_with_errorCallback</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileSystemManager_moveDirectory_with_errorCallback
+//==== LABEL Check if FileSystemManager::moveDirectory() method works properly with errorCallback
+//==== SPEC Tizen Web API:IO:Filesystem:FileSystemManager:moveDirectory M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P1
+//==== ONLOAD_DELAY 90
+//==== TEST_CRITERIA MOA MR MAST
+
+var t = async_test(document.title), moveDirectorySuccess, moveDirectoryError, retVal;
+
+t.step(function () {
+ add_result_callback(function () {
+ try {
+ tizen.filesystem.deleteDirectory("documents/foo_dir", true);
+ tizen.filesystem.deleteDirectory("documents/bar_dir", true);
+ } catch (err) {
+ }
+ });
+
+ moveDirectorySuccess = t.step_func(function () {
+ assert_equals(retVal, undefined, "return value should be undefined");
+ assert_true(!tizen.filesystem.pathExists("documents/foo_dir") && tizen.filesystem.pathExists("documents/bar_dir/foo_dir"),
+ "directory is not moved to the destination path successfully");
+ t.done();
+ });
+
+ moveDirectoryError = t.step_func(function (error) {
+ assert_unreached("moveDirectory() error callback invoked: name:" + error.name + "msg:" + error.message);
+ });
+
+ tizen.filesystem.createDirectory("documents/foo_dir");
+ tizen.filesystem.createDirectory("documents/bar_dir");
+ retVal = tizen.filesystem.moveDirectory("documents/foo_dir", "documents/bar_dir", false, moveDirectorySuccess, moveDirectoryError);
+});
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileSystemManager_moveFile</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileSystemManager_moveFile
+//==== LABEL Check if FileSystemManager::moveFile() method works properly
+//==== SPEC Tizen Web API:IO:Filesystem:FileSystemManager:moveFile M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P1
+//==== TEST_CRITERIA MR MMINA
+
+var t = async_test(document.title), retVal, fileRead, createDirectorySuccess, createDirectoryError;
+
+t.step(function () {
+ add_result_callback(function () {
+ try {
+ tizen.filesystem.deleteDirectory("documents/foo_dir", true);
+ tizen.filesystem.deleteFile("documents/foo");
+ } catch (err) {
+ }
+ });
+
+ createDirectorySuccess = t.step_func(function () {
+ fileRead = tizen.filesystem.openFile("documents/foo", "w");
+ fileRead.close();
+ retVal = tizen.filesystem.moveFile("documents/foo", "documents/foo_dir");
+ assert_equals(retVal, undefined, "return value should be undefined");
+ t.done();
+ });
+
+ createDirectoryError = t.step_func(function (error) {
+ assert_unreached("createDirectory() error callback invoked: name:" + error.name + "msg:" + error.message);
+ });
+
+ tizen.filesystem.createDirectory("documents/foo_dir", true, createDirectorySuccess, createDirectoryError);
+});
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileSystemManager_moveFile_InvalidValuesError</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileSystemManager_moveFile_InvalidValuesError
+//==== LABEL Check if FileSystemManager::moveFile() method with invalid path throws InvalidValuesError
+//==== SPEC Tizen Web API:IO:Filesystem:FileSystemManager:moveFile M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P2
+//==== ONLOAD_DELAY 90
+//==== TEST_CRITERIA MC
+
+var t = async_test(document.title), moveFileSuccess, moveFileError;
+
+t.step(function () {
+ moveFileSuccess = t.step_func(function () {
+ });
+
+ moveFileError = t.step_func(function (error) {
+ assert_unreached("moveFile() error callback invoked: name:" + error.name + "msg:" + error.message);
+ });
+
+ assert_throws(INVALID_VALUES_EXCEPTION, function () {
+ tizen.filesystem.moveFile("documents/foo", "notexist/folder", false, moveFileSuccess, moveFileError);
+ }, "InvalidValuesError should be thrown - invalid path.");
+ t.done();
+});
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileSystemManager_moveFile_errorCallback_invalid_cb</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileSystemManager_moveFile_errorCallback_invalid_cb
+//==== LABEL Check if FileSystemManager::moveFile() method throws exception when errorCallback is invalid
+//==== SPEC Tizen Web API:IO:Filesystem:FileSystemManager:moveFile M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P2
+//==== ONLOAD_DELAY 90
+//==== TEST_CRITERIA MTCB
+
+var t = async_test(document.title), moveFileSuccess, invalidCallback;
+
+t.step(function () {
+ add_result_callback(function () {
+ try {
+ tizen.filesystem.deleteFile("documents/foo");
+ tizen.filesystem.deleteDirectory("documents/foo_dir", true);
+ } catch (err) {
+ }
+ });
+
+ moveFileSuccess = t.step_func(function () {
+ assert_unreached("Should not be invoked moveFile SuccessCallback");
+ });
+
+ invalidCallback = {
+ onerror: t.step_func(function (error) {
+ assert_unreached("Invalid callback invoked");
+ })
+ };
+
+ tizen.filesystem.createDirectory("documents/foo_dir");
+ tizen.filesystem.openFile("documents/foo", "w");
+ assert_throws(TYPE_MISMATCH_EXCEPTION, function () {
+ tizen.filesystem.moveFile("documents/foo", "documents/foo_dir", false, moveFileSuccess, invalidCallback);
+ }, "given incorrect errorCallback");
+ t.done();
+});
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileSystemManager_moveFile_errorCallback_invoked_NotFoundError</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileSystemManager_moveFile_errorCallback_invoked_NotFoundError
+//==== LABEL Check if FileSystemManager::moveFile() method throws NotFoundError when path not exists
+//==== SPEC Tizen Web API:IO:Filesystem:FileSystemManager:moveFile M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P2
+//==== ONLOAD_DELAY 90
+//==== TEST_CRITERIA MERRCB
+
+var t = async_test(document.title), moveFileSuccess, moveFileError;
+
+t.step(function () {
+ moveFileSuccess = t.step_func(function () {
+ assert_unreached("Should not be invoked moveFile SuccessCallback");
+ });
+
+ moveFileError = t.step_func(function (error) {
+ assert_equals(error.name, "NotFoundError", "expect to throw an NotFoundError exception");
+ t.done();
+ });
+
+ tizen.filesystem.moveFile("documents/foo", "documents/foo_dir/wrong_dir", false, moveFileSuccess, moveFileError);
+});
+
+</script>
+</body>
+</html>
\ No newline at end of file
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileSystemManager_moveFile_exist</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileSystemManager_moveFile_exist
+//==== LABEL Check if FileSystemManager::moveFile() method exists
+//==== SPEC Tizen Web API:IO:Filesystem:FileSystemManager:moveFile M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P0
+//==== TEST_CRITERIA ME
+
+test(function () {
+ check_method_exists(tizen.filesystem, "moveFile");
+}, document.title);
+
+</script>
+</body>
+</html>
\ No newline at end of file
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileSystemManager_moveFile_misarg</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileSystemManager_moveFile_misarg
+//==== LABEL Check if FileSystemManager::moveFile() method with missing mandatory argument throws exception
+//==== SPEC Tizen Web API:IO:Filesystem:FileSystemManager:moveFile M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P2
+//==== TEST_CRITERIA MMA
+
+test(function () {
+ assert_throws(INVALID_VALUES_EXCEPTION, function () {
+ tizen.filesystem.moveFile();
+ }, "InvalidValuesError should be thrown.");
+}, document.title);
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileSystemManager_moveFile_onerror_TypeMismatch</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileSystemManager_moveFile_onerror_TypeMismatch
+//==== LABEL Check if FileSystemManager::moveFile() method throws exception for wrong type of onerror
+//==== SPEC Tizen Web API:IO:Filesystem:FileSystemManager:moveFile M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P2
+//==== ONLOAD_DELAY 90
+//==== TEST_CRITERIA MC
+
+var t = async_test(document.title), moveFileSuccess, moveFileError,
+ i, conversionTable, exceptionName = "TypeMismatchError";
+
+t.step(function () {
+ add_result_callback(function () {
+ try {
+ tizen.filesystem.deleteFile("documents/foo");
+ tizen.filesystem.deleteDirectory("documents/foo_dir", true);
+ } catch (err) {
+ }
+ });
+
+ moveFileSuccess = t.step_func(function () {
+ assert_unreached("Should not be invoked to moveFile Successcallback");
+ });
+
+ tizen.filesystem.createDirectory("documents/foo_dir");
+ tizen.filesystem.openFile("documents/foo", "w");
+
+ conversionTable = getTypeConversionExceptions("functionObject", true);
+ for (i = 0; i < conversionTable.length; i++) {
+ moveFileError = conversionTable[i][0];
+
+ assert_throws({name: exceptionName}, function () {
+ tizen.filesystem.moveFile("documents/foo", "documents/foo_dir", false, moveFileSuccess, moveFileError);
+ }, exceptionName + " should be thrown - given incorrect errorCallback.");
+ }
+ t.done();
+});
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileSystemManager_moveFile_onsuccess_TypeMismatch</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileSystemManager_moveFile_onsuccess_TypeMismatch
+//==== LABEL Check if FileSystemManager::moveFile() method throws exception for wrong type of onsuccess
+//==== SPEC Tizen Web API:IO:Filesystem:FileSystemManager:moveFile M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P2
+//==== ONLOAD_DELAY 90
+//==== TEST_CRITERIA MC
+
+var t = async_test(document.title), moveFileSuccess, moveFileError,
+ i, conversionTable, exceptionName = "TypeMismatchError";
+
+t.step(function () {
+ add_result_callback(function () {
+ try {
+ tizen.filesystem.deleteFile("documents/foo");
+ tizen.filesystem.deleteDirectory("documents/foo_dir", true);
+ } catch (err) {
+ }
+ });
+
+ moveFileError = t.step_func(function (error) {
+ assert_unreached("moveFile() error callback invoked: name:" + error.name + "msg:" + error.message);
+ });
+
+ tizen.filesystem.createDirectory("documents/foo_dir");
+ tizen.filesystem.openFile("documents/foo", "w");
+
+ conversionTable = getTypeConversionExceptions("functionObject", true);
+ for (i = 0; i < conversionTable.length; i++) {
+ moveFileSuccess = conversionTable[i][0];
+
+ assert_throws({name: exceptionName}, function () {
+ tizen.filesystem.moveFile("documents/foo", "documents/foo_dir", false, moveFileSuccess, moveFileError);
+ }, exceptionName + " should be thrown - given incorrect successCallback.");
+ }
+ t.done();
+});
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileSystemManager_moveFile_successCallback_invalid_cb</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileSystemManager_moveFile_successCallback_invalid_cb
+//==== LABEL Check if FileSystemManager::moveFile() method throws exception when successCallback is invalid
+//==== SPEC Tizen Web API:IO:Filesystem:FileSystemManager:moveFile M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P2
+//==== ONLOAD_DELAY 90
+//==== TEST_CRITERIA MTCB
+
+var t = async_test(document.title), invalidCallback, moveFileError;
+
+t.step(function () {
+ add_result_callback(function () {
+ try {
+ tizen.filesystem.deleteFile("documents/foo");
+ tizen.filesystem.deleteDirectory("documents/foo_dir", true);
+ } catch (err) {
+ }
+ });
+
+ invalidCallback = {
+ onsuccess: t.step_func(function () {
+ assert_unreached("Invalid callback invoked");
+ })
+ };
+
+ moveFileError = t.step_func(function (error) {
+ assert_unreached("moveFile() error callback invoked: name:" + error.name + "msg:" + error.message);
+ });
+
+ tizen.filesystem.createDirectory("documents/foo_dir");
+ tizen.filesystem.openFile("documents/foo", "w");
+ assert_throws(TYPE_MISMATCH_EXCEPTION, function () {
+ tizen.filesystem.moveFile("documents/foo", "documents/foo_dir", false, invalidCallback, moveFileError);
+ }, "given incorrect successCallback");
+ t.done();
+});
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileSystemManager_moveFile_with_errorCallback</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileSystemManager_moveFile_with_errorCallback
+//==== LABEL Check if FileSystemManager::moveFile() method works properly with errorCallback
+//==== SPEC Tizen Web API:IO:Filesystem:FileSystemManager:moveFile M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P1
+//==== ONLOAD_DELAY 90
+//==== TEST_CRITERIA MOA MR MAST
+
+var t = async_test(document.title), moveFileSuccess, moveFileError, retVal, fileRead,
+ createDirectorySuccess, createDirectoryError;
+
+t.step(function () {
+ add_result_callback(function () {
+ try {
+ tizen.filesystem.deleteDirectory("documents/foo_dir", true);
+ tizen.filesystem.deleteFile("documents/foo");
+ } catch (err) {
+ }
+ });
+
+ moveFileSuccess = t.step_func(function () {
+ assert_equals(retVal, undefined, "return value should be undefined");
+ assert_true(!tizen.filesystem.pathExists("documents/foo") && tizen.filesystem.pathExists("documents/foo_dir/foo"),
+ "file is not moved to the destination path successfully");
+ t.done();
+ });
+
+ moveFileError = t.step_func(function (error) {
+ assert_unreached("moveFile() error callback invoked: name:" + error.name + "msg:" + error.message);
+ });
+
+ createDirectorySuccess = t.step_func(function () {
+ fileRead = tizen.filesystem.openFile("documents/foo", "w");
+ fileRead.close();
+ retVal = tizen.filesystem.moveFile("documents/foo", "documents/foo_dir", false, moveFileSuccess, moveFileError);
+ });
+
+ createDirectoryError = t.step_func(function (error) {
+ assert_unreached("createDirectory() error callback invoked: name:" + error.name + "msg:" + error.message);
+ });
+
+ tizen.filesystem.createDirectory("documents/foo_dir", true, createDirectorySuccess, createDirectoryError);
+});
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileSystemManager_openFile</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileSystemManager_openFile
+//==== LABEL Check if FileSystemManager::openFile() method works properly
+//==== SPEC Tizen Web API:IO:Filesystem:FileSystemManager:openFile M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P1
+//==== TEST_CRITERIA MR MMINA
+
+test(function () {
+ var fileHandleWrite;
+
+ add_result_callback(function () {
+ try {
+ tizen.filesystem.deleteFile("documents/file");
+ } catch (err) {
+ }
+ });
+
+ fileHandleWrite = tizen.filesystem.openFile("documents/file", "w");
+ assert_type(fileHandleWrite, "object", "FileHandle write should be an object.");
+ assert_equals(fileHandleWrite.path, "documents/file", "The attribute path is the same as openFile path");
+ fileHandleWrite.close();
+}, document.title);
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileSystemManager_openFile_IOError</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileSystemManager_openFile_IOError
+//==== LABEL Check if FileSystemManager::openFile() method throws IOError when IO error occurs
+//==== SPEC Tizen Web API:IO:Filesystem:FileSystemManager:openFile M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P2
+//==== TEST_CRITERIA MC
+
+test(function () {
+ var fileWrite, text = "", i, possible = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789";
+
+ for (i = 0; i < tizen.filesystem.maxPathLength; i++)
+ text += possible.charAt(Math.floor(Math.random() * possible.length));
+
+ assert_throws(IO_EXCEPTION, function () {
+ tizen.filesystem.openFile("documents/"+ text, "w");
+ }, "IOError should be thrown - when IO error occurs.");
+}, document.title);
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileSystemManager_openFile_NotFoundError</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileSystemManager_openFile_NotFoundError
+//==== LABEL Check if FileSystemManager::openFile() method throws NotFoundError when file not exists
+//==== SPEC Tizen Web API:IO:Filesystem:FileSystemManager:openFile M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P2
+//==== TEST_CRITERIA MC
+
+test(function () {
+ assert_throws(NOT_FOUND_EXCEPTION, function () {
+ tizen.filesystem.openFile("documents/notexist", "r");
+ }, "NotFoundError should be thrown - file not exists.");
+}, document.title);
+
+</script>
+</body>
+</html>
\ No newline at end of file
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileSystemManager_openFile_exist</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileSystemManager_openFile_exist
+//==== LABEL Check if FileSystemManager::openFile() method exists
+//==== SPEC Tizen Web API:IO:Filesystem:FileSystemManager:openFile M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P0
+//==== TEST_CRITERIA ME
+
+test(function () {
+ check_method_exists(tizen.filesystem, "openFile");
+}, document.title);
+
+</script>
+</body>
+</html>
\ No newline at end of file
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileSystemManager_openFile_misarg</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileSystemManager_openFile_misarg
+//==== LABEL Check if FileSystemManager::openFile() method with missing mandatory argument throws exception
+//==== SPEC Tizen Web API:IO:Filesystem:FileSystemManager:openFile M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P2
+//==== TEST_CRITERIA MMA
+
+test(function () {
+ assert_throws(TYPE_MISMATCH_EXCEPTION, function () {
+ tizen.filesystem.openFile();
+ }, "TypeMismatchError should be thrown.");
+}, document.title);
+
+</script>
+</body>
+</html>
\ No newline at end of file
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileSystemManager_openFile_with_makeParents</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileSystemManager_openFile_with_makeParents
+//==== LABEL Check if FileSystemManager::openFile() method works properly with makeParents
+//==== SPEC Tizen Web API:IO:Filesystem:FileSystemManager:openFile M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P1
+//==== TEST_CRITERIA MOA MR
+
+test(function () {
+ var fileHandleWrite;
+
+ add_result_callback(function () {
+ try {
+ fileHandleWrite.close();
+ tizen.filesystem.deleteFile("documents/file");
+ } catch (err) {
+ }
+ });
+
+ fileHandleWrite = tizen.filesystem.openFile("documents/file", "w", true);
+ assert_type(fileHandleWrite, "object", "FileHandle write should be an object.");
+ assert_equals(fileHandleWrite.path, "documents/file", "The attribute path is the same as openFile path");
+}, document.title);
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileSystemManager_pathExists</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileSystemManager_pathExists
+//==== LABEL Check if FileSystemManager::pathExists() method works properly
+//==== SPEC Tizen Web API:IO:Filesystem:FileSystemManager:pathExists M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P1
+//==== TEST_CRITERIA MR
+
+test(function () {
+ var retVal, fileHandle;
+
+ add_result_callback(function () {
+ try {
+ tizen.filesystem.deleteFile("documents/foo");
+ } catch (err) {
+ }
+ });
+
+ fileHandle = tizen.filesystem.openFile("documents/foo", "w");
+ fileHandle.close();
+ retVal = tizen.filesystem.pathExists("documents/foo");
+ assert_type(retVal, "boolean", "Type of return value should be of boolean.");
+ assert_true(retVal, "The path does not exist.");
+}, document.title);
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileSystemManager_pathExists_InvalidValuesError</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileSystemManager_pathExists_InvalidValuesError
+//==== LABEL Check if FileSystemManager::pathExists() method with invalid path throws InvalidValuesError
+//==== SPEC Tizen Web API:IO:Filesystem:FileSystemManager:pathExists M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P2
+//==== TEST_CRITERIA MC
+
+test(function () {
+ assert_throws(INVALID_VALUES_EXCEPTION, function () {
+ tizen.filesystem.pathExists("notexist/folder");
+ }, "InvalidValuesError should be thrown - invalid path.");
+}, document.title);
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileSystemManager_pathExists_exist</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileSystemManager_pathExists_exist
+//==== LABEL Check if FileSystemManager::pathExists() method exists
+//==== SPEC Tizen Web API:IO:Filesystem:FileSystemManager:pathExists M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P0
+//==== TEST_CRITERIA ME
+
+test(function () {
+ check_method_exists(tizen.filesystem, "pathExists");
+}, document.title);
+
+</script>
+</body>
+</html>
\ No newline at end of file
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileSystemManager_rename</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileSystemManager_rename
+//==== LABEL Check if FileSystemManager::rename() method works properly
+//==== SPEC Tizen Web API:IO:Filesystem:FileSystemManager:rename M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P1
+//==== TEST_CRITERIA MR MMINA
+
+test(function () {
+ var retVal, fileWrite;
+
+ add_result_callback(function () {
+ try {
+ tizen.filesystem.deleteFile("documents/foo");
+ tizen.filesystem.deleteFile("documents/bar");
+ } catch (err) {
+ }
+ });
+
+ fileWrite = tizen.filesystem.openFile("documents/foo", "w");
+ fileWrite.close();
+
+ retVal = tizen.filesystem.rename("documents/foo", "bar");
+ assert_equals(retVal, undefined, "return value should be undefined");
+}, document.title);
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileSystemManager_rename_InvalidValuesError</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileSystemManager_rename_InvalidValuesError
+//==== LABEL Check if FileSystemManager::rename() method with invalid name throws InvalidValuesError
+//==== SPEC Tizen Web API:IO:Filesystem:FileSystemManager:rename M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P2
+//==== ONLOAD_DELAY 90
+//==== TEST_CRITERIA MC
+
+var t = async_test(document.title), renameSuccess, renameError;
+
+t.step(function () {
+ add_result_callback(function () {
+ try {
+ tizen.filesystem.deleteFile("documents/foo");
+ } catch (err) {
+ }
+ });
+
+ renameSuccess = t.step_func(function () {
+ });
+
+ renameError = t.step_func(function (error) {
+ assert_unreached("rename() error callback invoked: name:" + error.name + "msg:" + error.message);
+ });
+
+ tizen.filesystem.openFile("documents/foo", "w");
+ assert_throws(INVALID_VALUES_EXCEPTION, function () {
+ tizen.filesystem.rename("documents/foo", "notexist/folder", renameSuccess, renameError);
+ }, "InvalidValuesError should be thrown - invalid name.");
+ t.done();
+});
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileSystemManager_rename_errorCallback_invalid_cb</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileSystemManager_rename_errorCallback_invalid_cb
+//==== LABEL Check if FileSystemManager::rename() method throws exception when errorCallback is invalid
+//==== SPEC Tizen Web API:IO:Filesystem:FileSystemManager:rename M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P2
+//==== ONLOAD_DELAY 90
+//==== TEST_CRITERIA MTCB
+
+var t = async_test(document.title), renameSuccess, invalidCallback;
+
+t.step(function () {
+ add_result_callback(function () {
+ try {
+ tizen.filesystem.deleteFile("documents/foo");
+ } catch (err) {
+ }
+ });
+
+ renameSuccess = t.step_func(function () {
+ assert_unreached("Should not be invoked rename SuccessCallback");
+ });
+
+ invalidCallback = {
+ onerror: t.step_func(function (error) {
+ assert_unreached("Invalid callback invoked");
+ })
+ };
+
+ tizen.filesystem.openFile("documents/foo", "w");
+ assert_throws(TYPE_MISMATCH_EXCEPTION, function () {
+ tizen.filesystem.rename("documents/foo", "bar", renameSuccess, invalidCallback);
+ }, "given incorrect errorCallback");
+ t.done();
+});
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileSystemManager_rename_errorCallback_invoked_IOError</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileSystemManager_rename_errorCallback_invoked_IOError
+//==== LABEL Check if FileSystemManager::rename() method throws IOError if conflicting file name exists
+//==== SPEC Tizen Web API:IO:Filesystem:FileSystemManager:rename M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P2
+//==== ONLOAD_DELAY 90
+//==== TEST_CRITERIA MERRCB
+
+var t = async_test(document.title), fileHandleRead1, fileHandleRead2, renameSuccess, renameError;
+
+t.step(function () {
+ add_result_callback(function () {
+ try {
+ tizen.filesystem.deleteFile("documents/foo");
+ tizen.filesystem.deleteFile("documents/bar");
+ } catch (err) {
+ }
+ });
+
+ renameSuccess = t.step_func(function () {
+ assert_unreached("Should not be invoked rename SuccessCallback");
+ });
+
+ renameError = t.step_func(function (error) {
+ assert_equals(error.name, "IOError", "expect to throw an IOError exception");
+ t.done();
+ });
+
+ fileHandleRead1 = tizen.filesystem.openFile("documents/foo", "w");
+ fileHandleRead1.close();
+ fileHandleRead2 = tizen.filesystem.openFile("documents/bar", "w");
+ fileHandleRead2.close();
+ tizen.filesystem.rename("documents/foo", "bar", renameSuccess, renameError);
+});
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileSystemManager_rename_errorCallback_invoked_NotFoundError</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileSystemManager_rename_errorCallback_invoked_NotFoundError
+//==== LABEL Check if FileSystemManager::rename() method throws NotFoundError if path points to non-existing file
+//==== SPEC Tizen Web API:IO:Filesystem:FileSystemManager:rename M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P2
+//==== ONLOAD_DELAY 90
+//==== TEST_CRITERIA MERRCB
+
+var t = async_test(document.title), renameSuccess, renameError;
+
+t.step(function () {
+ renameSuccess = t.step_func(function () {
+ assert_unreached("Should not be invoked rename SuccessCallback");
+ });
+
+ renameError = t.step_func(function (error) {
+ assert_equals(error.name, "NotFoundError", "expect to throw an NotFoundError exception");
+ t.done();
+ });
+
+ tizen.filesystem.rename("documents/notexist", "bar", renameSuccess, renameError);
+});
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileSystemManager_rename_exist</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileSystemManager_rename_exist
+//==== LABEL Check if FileSystemManager::rename() method exists
+//==== SPEC Tizen Web API:IO:Filesystem:FileSystemManager:rename M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P0
+//==== TEST_CRITERIA ME
+
+test(function () {
+ check_method_exists(tizen.filesystem, "rename");
+}, document.title);
+
+</script>
+</body>
+</html>
\ No newline at end of file
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileSystemManager_rename_misarg</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileSystemManager_rename_misarg
+//==== LABEL Check if FileSystemManager::rename() method with missing mandatory argument throws exception
+//==== SPEC Tizen Web API:IO:Filesystem:FileSystemManager:rename M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P2
+//==== TEST_CRITERIA MMA
+
+test(function () {
+ assert_throws(INVALID_VALUES_EXCEPTION, function () {
+ tizen.filesystem.rename();
+ }, "InvalidValuesError should be thrown.");
+}, document.title);
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileSystemManager_rename_onerror_TypeMismatch</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileSystemManager_rename_onerror_TypeMismatch
+//==== LABEL Check if FileSystemManager::rename() method throws exception for wrong type of onerror
+//==== SPEC Tizen Web API:IO:Filesystem:FileSystemManager:rename M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P2
+//==== ONLOAD_DELAY 90
+//==== TEST_CRITERIA MC
+
+var t = async_test(document.title), renameSuccess, renameError,
+ i, conversionTable, exceptionName = "TypeMismatchError";
+
+t.step(function () {
+ add_result_callback(function () {
+ try {
+ tizen.filesystem.deleteFile("documents/foo");
+ } catch (err) {
+ }
+ });
+
+ renameSuccess = t.step_func(function () {
+ assert_unreached("Should not be invoked to rename Successcallback");
+ });
+
+ tizen.filesystem.openFile("documents/foo", "w");
+ conversionTable = getTypeConversionExceptions("functionObject", true);
+ for (i = 0; i < conversionTable.length; i++) {
+ renameError = conversionTable[i][0];
+
+ assert_throws({name: exceptionName}, function () {
+ tizen.filesystem.rename("documents/foo", "bar", renameSuccess, renameError);
+ }, exceptionName + " should be thrown - given incorrect errorCallback.");
+ }
+
+ t.done();
+});
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileSystemManager_rename_onsuccess_TypeMismatch</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileSystemManager_rename_onsuccess_TypeMismatch
+//==== LABEL Check if FileSystemManager::rename() method throws exception for wrong type of onsuccess
+//==== SPEC Tizen Web API:IO:Filesystem:FileSystemManager:rename M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P2
+//==== ONLOAD_DELAY 90
+//==== TEST_CRITERIA MC
+
+var t = async_test(document.title), renameSuccess, renameError,
+ i, conversionTable, exceptionName = "TypeMismatchError";
+
+t.step(function () {
+ add_result_callback(function () {
+ try {
+ tizen.filesystem.deleteFile("documents/foo");
+ } catch (err) {
+ }
+ });
+
+ renameError = t.step_func(function (error) {
+ assert_unreached("rename() error callback invoked: name:" + error.name + "msg:" + error.message);
+ });
+
+ tizen.filesystem.openFile("documents/foo", "w");
+ conversionTable = getTypeConversionExceptions("functionObject", true);
+ for (i = 0; i < conversionTable.length; i++) {
+ renameSuccess = conversionTable[i][0];
+
+ assert_throws({name: exceptionName}, function () {
+ tizen.filesystem.rename("documents/foo", "bar", renameSuccess, renameError);
+ }, exceptionName + " should be thrown - given incorrect successCallback.");
+ }
+
+ t.done();
+});
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileSystemManager_rename_successCallback_invalid_cb</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileSystemManager_rename_successCallback_invalid_cb
+//==== LABEL Check if FileSystemManager::rename() method throws exception when successCallback is invalid
+//==== SPEC Tizen Web API:IO:Filesystem:FileSystemManager:rename M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P2
+//==== ONLOAD_DELAY 90
+//==== TEST_CRITERIA MTCB
+
+var t = async_test(document.title), invalidCallback, renameError;
+
+t.step(function () {
+ add_result_callback(function () {
+ try {
+ tizen.filesystem.deleteFile("documents/foo");
+ } catch (err) {
+ }
+ });
+
+ invalidCallback = {
+ onsuccess: t.step_func(function () {
+ assert_unreached("Invalid callback invoked");
+ })
+ };
+
+ renameError = t.step_func(function (error) {
+ assert_unreached("rename() error callback invoked: name:" + error.name + "msg:" + error.message);
+ });
+
+ tizen.filesystem.openFile("documents/foo", "w");
+ assert_throws(TYPE_MISMATCH_EXCEPTION, function () {
+ tizen.filesystem.rename("documents/foo", "bar", invalidCallback, renameError);
+ }, "given incorrect successCallback");
+
+ t.done();
+});
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileSystemManager_rename_with_errorCallback</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileSystemManager_rename_with_errorCallback
+//==== LABEL Check if FileSystemManager::rename() method works properly with errorCallback
+//==== SPEC Tizen Web API:IO:Filesystem:FileSystemManager:rename M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P1
+//==== ONLOAD_DELAY 90
+//==== TEST_CRITERIA MOA MR MAST
+
+var t = async_test(document.title), renameSuccess, renameError, retVal;
+
+t.step(function () {
+ add_result_callback(function () {
+ try {
+ tizen.filesystem.deleteFile("documents/foo");
+ tizen.filesystem.deleteFile("documents/bar");
+ } catch (err) {
+ }
+ });
+
+ renameSuccess = t.step_func(function () {
+ assert_equals(retVal, undefined, "return value should be undefined");
+ assert_true(!tizen.filesystem.pathExists("documents/foo") && tizen.filesystem.pathExists("documents/bar"),
+ "file is not renamed successfully");
+ t.done();
+ });
+
+ renameError = t.step_func(function (error) {
+ assert_unreached("rename() error callback invoked: name:" + error.name + "msg:" + error.message);
+ });
+
+ tizen.filesystem.openFile("documents/foo", "w");
+ retVal = tizen.filesystem.rename("documents/foo", "bar", renameSuccess, renameError);
+});
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileSystemManager_toURI</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileSystemManager_toURI
+//==== LABEL Check if FileSystemManager::toURI() method works properly
+//==== SPEC Tizen Web API:IO:Filesystem:FileSystemManager:toURI M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P1
+//==== TEST_CRITERIA MR
+
+test(function () {
+ var retVal;
+
+ retVal = tizen.filesystem.toURI("documents/directory/file.ext");
+ assert_type(retVal, "string", "The type of return value should be string.");
+ assert_equals(retVal, "file:///opt/usr/home/owner/media/Documents/directory/file.ext", "Path is not successfully converted to file URI");
+}, document.title);
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileSystemManager_toURI_InvalidValuesError</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileSystemManager_toURI_InvalidValuesError
+//==== LABEL Check if FileSystemManager::toURI() method with invalid path throws InvalidValuesError
+//==== SPEC Tizen Web API:IO:Filesystem:FileSystemManager:toURI M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P2
+//==== TEST_CRITERIA MC
+
+test(function () {
+ assert_throws(INVALID_VALUES_EXCEPTION, function () {
+ tizen.filesystem.toURI("notexist/folder/file.ext");
+ }, "InvalidValuesError should be thrown - invalid path.");
+}, document.title);
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>FileSystemManager_toURI_exist</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: FileSystemManager_toURI_exist
+//==== LABEL Check if FileSystemManager::toURI() method exists
+//==== SPEC Tizen Web API:IO:Filesystem:FileSystemManager:toURI M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P0
+//==== TEST_CRITERIA ME
+
+test(function () {
+ check_method_exists(tizen.filesystem, "toURI");
+}, document.title);
+
+</script>
+</body>
+</html>
\ No newline at end of file
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>ListDirectorySuccessCallback_notexist</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: ListDirectorySuccessCallback_notexist
+//==== LABEL Check if interface ListDirectorySuccessCallback exists, it should not
+//==== SPEC Tizen Web API:IO:Filesystem:ListDirectorySuccessCallback:ListDirectorySuccessCallback U
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P3
+//==== TEST_CRITERIA CBNIO
+
+test(function () {
+ check_no_interface_object("ListDirectorySuccessCallback");
+}, document.title);
+
+</script>
+</body>
+</html>
\ No newline at end of file
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>ListDirectorySuccessCallback_onsuccess</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: ListDirectorySuccessCallback_onsuccess
+//==== LABEL Check if ListDirectorySuccessCallback::onsuccess() works properly
+//==== SPEC Tizen Web API:IO:Filesystem:ListDirectorySuccessCallback:onsuccess M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P1
+//==== ONLOAD_DELAY 90
+//==== TEST_CRITERIA CBOA CBT
+
+var t = async_test(document.title), listDirectorySuccess, listDirectoryError,
+ createDirectorySuccess, createDirectoryError;
+
+t.step(function () {
+ add_result_callback(function () {
+ try {
+ tizen.filesystem.deleteDirectory("documents/foo_dir");
+ } catch (err) {
+ }
+ });
+
+ listDirectorySuccess = t.step_func(function (files) {
+ assert_type(files, "array", "The files isn't an array");
+ assert_greater_than_equal(files.length, 1, "Not successfully list directory content");
+ t.done();
+ });
+
+ listDirectoryError = t.step_func(function (error) {
+ assert_unreached("listDirectory() error callback invoked: name:" + error.name + "msg:" + error.message);
+ });
+
+ createDirectorySuccess = t.step_func(function () {
+ tizen.filesystem.listDirectory("documents/", listDirectorySuccess, listDirectoryError, {name: "foo_%"});
+ });
+
+ createDirectoryError = t.step_func(function (error) {
+ assert_unreached("createDirectory() error callback invoked: name:" + error.name + "msg:" + error.message);
+ });
+
+ tizen.filesystem.createDirectory("documents/foo_dir", true, createDirectorySuccess, createDirectoryError);
+});
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>ReadBlobSuccessCallback_notexist</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: ReadBlobSuccessCallback_notexist
+//==== LABEL Check if interface ReadBlobSuccessCallback exists, it should not
+//==== SPEC Tizen Web API:IO:Filesystem:ReadBlobSuccessCallback:ReadBlobSuccessCallback U
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P3
+//==== TEST_CRITERIA CBNIO
+
+test(function () {
+ check_no_interface_object("ReadBlobSuccessCallback");
+}, document.title);
+
+</script>
+</body>
+</html>
\ No newline at end of file
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>ReadBlobSuccessCallback_onsuccess</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: ReadBlobSuccessCallback_onsuccess
+//==== LABEL Check if ReadBlobSuccessCallback::onsuccess() works properly
+//==== SPEC Tizen Web API:IO:Filesystem:ReadBlobSuccessCallback:onsuccess M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P1
+//==== ONLOAD_DELAY 90
+//==== TEST_CRITERIA CBOA CBT
+
+var t = async_test(document.title), writeBlobNonBlockingSuccess, writeBlobNonBlockingError,
+ fileHandleWrite, fileHandleRead, readBlobNonBlockingSuccess, readBlobNonBlockingError,
+ blob, content = "Lorem ipsum dolor sit amet...", fileContentsInBlob;
+
+t.step(function () {
+ add_result_callback(function () {
+ try {
+ tizen.filesystem.deleteFile("documents/file");
+ } catch (err) {
+ }
+ });
+
+ writeBlobNonBlockingSuccess = t.step_func(function (blob) {
+ });
+
+ writeBlobNonBlockingError = t.step_func(function (error) {
+ assert_unreached("writeBlobNonBlocking() error callback invoked: name:" + error.name + "msg:" + error.message);
+ });
+
+ readBlobNonBlockingSuccess = t.step_func(function (fileContentsInBlob) {
+ assert_type(fileContentsInBlob, "object", "The file contents blob should be an object.");
+ assert_true(fileContentsInBlob instanceof Blob, "The file contents blob should be instance of Blob object");
+ fileHandleRead.close();
+ t.done();
+ });
+
+ readBlobNonBlockingError = t.step_func(function (error) {
+ assert_unreached("readBlobNonBlocking() error callback invoked: name:" + error.name + "msg:" + error.message);
+ });
+
+ blob = new Blob([content], {type: "text/plain"});
+ fileHandleWrite = tizen.filesystem.openFile("documents/file", "w");
+ fileHandleWrite.writeBlobNonBlocking(blob, writeBlobNonBlockingSuccess, writeBlobNonBlockingError);
+ fileHandleWrite.close();
+
+ fileHandleRead = tizen.filesystem.openFile("documents/file", "r");
+ fileHandleRead.readBlobNonBlocking(readBlobNonBlockingSuccess, readBlobNonBlockingError);
+});
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>ReadDataSuccessCallback_notexist</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: ReadDataSuccessCallback_notexist
+//==== LABEL Check if interface ReadDataSuccessCallback exists, it should not
+//==== SPEC Tizen Web API:IO:Filesystem:ReadDataSuccessCallback:ReadDataSuccessCallback U
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P3
+//==== TEST_CRITERIA CBNIO
+
+test(function () {
+ check_no_interface_object("ReadDataSuccessCallback");
+}, document.title);
+
+</script>
+</body>
+</html>
\ No newline at end of file
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>ReadDataSuccessCallback_onsuccess</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: ReadDataSuccessCallback_onsuccess
+//==== LABEL Check if ReadDataSuccessCallback::onsuccess() works properly
+//==== SPEC Tizen Web API:IO:Filesystem:ReadDataSuccessCallback:onsuccess M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P1
+//==== ONLOAD_DELAY 90
+//==== TEST_CRITERIA CBOA CBT
+
+var t = async_test(document.title), dataToWrite = new Uint8Array([11, 21, 31, 71, 81, 91]), writeDataNonBlockingSuccess, writeDataNonBlockingError,
+ readDataNonBlockingSuccess, readDataNonBlockingError, fileHandleWrite, fileHandleRead;
+
+t.step(function () {
+ add_result_callback(function () {
+ try {
+ tizen.filesystem.deleteFile("documents/file");
+ } catch (err) {
+ }
+ });
+
+ writeDataNonBlockingSuccess = t.step_func(function () {
+ });
+
+ writeDataNonBlockingError = t.step_func(function (error) {
+ assert_unreached("writeDataNonBlocking() error callback invoked: name:" + error.name + "msg:" + error.message);
+ });
+
+ readDataNonBlockingSuccess = t.step_func(function (data) {
+ assert_type(data, "object", "The type returned should be of object type.");
+ assert_equals(data.length, 3, "Data read from file is not right");
+ fileHandleRead.close();
+ t.done();
+ });
+
+ readDataNonBlockingError = t.step_func(function (error) {
+ assert_unreached("readDataNonBlocking() error callback invoked: name:" + error.name + "msg:" + error.message);
+ });
+
+ fileHandleWrite = tizen.filesystem.openFile("documents/file", "w");
+ fileHandleWrite.writeDataNonBlocking(dataToWrite, writeDataNonBlockingSuccess, writeDataNonBlockingError);
+ fileHandleWrite.close();
+
+ fileHandleRead = tizen.filesystem.openFile("documents/file", "r");
+ fileHandleRead.readDataNonBlocking(readDataNonBlockingSuccess, readDataNonBlockingError, 3);
+});
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>ReadStringSuccessCallback_notexist</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: ReadStringSuccessCallback_notexist
+//==== LABEL Check if interface ReadStringSuccessCallback exists, it should not
+//==== SPEC Tizen Web API:IO:Filesystem:ReadStringSuccessCallback:ReadStringSuccessCallback U
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P3
+//==== TEST_CRITERIA CBNIO
+
+test(function () {
+ check_no_interface_object("ReadStringSuccessCallback");
+}, document.title);
+
+</script>
+</body>
+</html>
\ No newline at end of file
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>ReadStringSuccessCallback_onsuccess</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: ReadStringSuccessCallback_onsuccess
+//==== LABEL Check if ReadStringSuccessCallback::onsuccess() works properly
+//==== SPEC Tizen Web API:IO:Filesystem:ReadStringSuccessCallback:onsuccess M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P1
+//==== ONLOAD_DELAY 90
+//==== TEST_CRITERIA CBOA CBT
+
+var t = async_test(document.title), writeStringNonBlockingSuccess, writeStringNonBlockingError,
+ readStringNonBlockingSuccess, readStringNonBlockingError, fileHandleWrite, content = "Lorem ipsum dolor sit amet...";
+
+t.step(function () {
+ add_result_callback(function () {
+ try {
+ tizen.filesystem.deleteFile("documents/file");
+ } catch (err) {
+ }
+ });
+
+ writeStringNonBlockingSuccess = t.step_func(function (bytesCount) {
+ });
+
+ writeStringNonBlockingError = t.step_func(function (error) {
+ assert_unreached("writeStringNonBlocking() error callback invoked: name:" + error.name + "msg:" + error.message);
+ });
+
+ readStringNonBlockingSuccess = t.step_func(function (output) {
+ assert_equals(output, content.substring(0, 5), "Data read from file is not right.");
+ fileHandleRead.close();
+ t.done();
+ });
+
+ readStringNonBlockingError = t.step_func(function (error) {
+ assert_unreached("readStringNonBlocking() error callback invoked: name:" + error.name + "msg:" + error.message);
+ });
+
+ fileHandleWrite = tizen.filesystem.openFile("documents/file", "w");
+ fileHandleWrite.writeStringNonBlocking(content, writeStringNonBlockingSuccess, writeStringNonBlockingError);
+ fileHandleWrite.close();
+
+ fileHandleRead = tizen.filesystem.openFile("documents/file", "r");
+ fileHandleRead.readStringNonBlocking(readStringNonBlockingSuccess, readStringNonBlockingError, 5, "UTF-8");
+});
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>SeekSuccessCallback_notexist</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: SeekSuccessCallback_notexist
+//==== LABEL Check if interface SeekSuccessCallback exists, it should not
+//==== SPEC Tizen Web API:IO:Filesystem:SeekSuccessCallback:SeekSuccessCallback U
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P3
+//==== TEST_CRITERIA CBNIO
+
+test(function () {
+ check_no_interface_object("SeekSuccessCallback");
+}, document.title);
+
+</script>
+</body>
+</html>
\ No newline at end of file
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>SeekSuccessCallback_onsuccess</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: SeekSuccessCallback_onsuccess
+//==== LABEL Check if SeekSuccessCallback::onsuccess() works properly
+//==== SPEC Tizen Web API:IO:Filesystem:SeekSuccessCallback:onsuccess M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P1
+//==== ONLOAD_DELAY 90
+//==== TEST_CRITERIA CBOA CBT
+
+var t = async_test(document.title), writeStringNonBlockingSuccess, writeStringNonBlockingError,
+ seekNonBlockingSuccess, seekNonBlockingError, fileHandleWrite;
+
+t.step(function () {
+ add_result_callback(function () {
+ try {
+ fileHandleWrite.close();
+ tizen.filesystem.deleteFile("documents/file");
+ } catch (err) {
+ }
+ });
+
+ writeStringNonBlockingSuccess = t.step_func(function (bytesCount) {
+ });
+
+ writeStringNonBlockingError = t.step_func(function (error) {
+ assert_unreached("writeStringNonBlocking() error callback invoked: name:" + error.name + "msg:" + error.message);
+ });
+
+ seekNonBlockingSuccess = t.step_func(function (position) {
+ assert_type(position, "long long", "The position isn't a number");
+ assert_equals(position, 3, "The seek position is not right");
+ t.done();
+ });
+
+ seekNonBlockingError = t.step_func(function (error) {
+ assert_unreached("seekNonBlocking() error callback invoked: name:" + error.name + "msg:" + error.message);
+ });
+
+ fileHandleWrite = tizen.filesystem.openFile("documents/file", "w");
+ fileHandleWrite.writeStringNonBlocking("Lorem ipsum dolor sit amet...", writeStringNonBlockingSuccess, writeStringNonBlockingError);
+ fileHandleWrite.seekNonBlocking(3, seekNonBlockingSuccess, seekNonBlockingError);
+});
+
+</script>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>WriteStringSuccessCallback_notexist</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: WriteStringSuccessCallback_notexist
+//==== LABEL Check if interface WriteStringSuccessCallback exists, it should not
+//==== SPEC Tizen Web API:IO:Filesystem:WriteStringSuccessCallback:WriteStringSuccessCallback U
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P3
+//==== TEST_CRITERIA CBNIO
+
+test(function () {
+ check_no_interface_object("WriteStringSuccessCallback");
+}, document.title);
+
+</script>
+</body>
+</html>
\ No newline at end of file
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2018 Samsung Electronics 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.
+
+Authors:
+ Qunfang Lin <qunfang.lin@samsung.com>
+
+-->
+
+<html>
+<head>
+<title>WriteStringSuccessCallback_onsuccess</title>
+<meta charset="utf-8"/>
+<script src="support/unitcommon.js"></script>
+</head>
+<body>
+<div id="log"></div>
+<script>
+//==== TEST: WriteStringSuccessCallback_onsuccess
+//==== LABEL Check if WriteStringSuccessCallback::onsuccess() works properly
+//==== SPEC Tizen Web API:IO:Filesystem:WriteStringSuccessCallback:onsuccess M
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html
+//==== PRIORITY P1
+//==== ONLOAD_DELAY 90
+//==== TEST_CRITERIA CBOA CBT
+
+var t = async_test(document.title), writeStringNonBlockingSuccess, writeStringNonBlockingError,
+ fileHandleWrite, content = "Lorem ipsum dolor sit amet...";
+
+t.step(function () {
+ add_result_callback(function () {
+ try {
+ fileHandleWrite.close();
+ tizen.filesystem.deleteFile("documents/file");
+ } catch (err) {
+ }
+ });
+
+ writeStringNonBlockingSuccess = t.step_func(function (bytesCount) {
+ assert_type(bytesCount, "long long", "The bytesCount isn't a number");
+ assert_equals(bytesCount, 29, "The written conent bytes count is not right.");
+ t.done();
+ });
+
+ writeStringNonBlockingError = t.step_func(function (error) {
+ assert_unreached("writeStringNonBlocking() error callback invoked: name:" + error.name + "msg:" + error.message);
+ });
+
+ fileHandleWrite = tizen.filesystem.openFile("documents/file", "w");
+ fileHandleWrite.writeStringNonBlocking(content, writeStringNonBlockingSuccess, writeStringNonBlockingError, "UTF-8");
+});
+
+</script>
+</body>
+</html>
UNKNOWN_EXCEPTION = {name: 'UnknownError'};
IO_EXCEPTION = {name: 'IOError'};
SECURITY_EXCEPTION = {name: 'SecurityError'};
+NOT_SUPPORTED_EXCEPTION = {name: 'NotSupportedError'};
(function () {
</spec>
</specs>
</testcase>
+ <testcase purpose="Check if FileHandle::close() method works properly" type="compliance" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P1" id="FileHandle_close">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_close.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileHandle" element_type="method" element_name="close" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileHandle::closeNonBlocking() method works properly" type="compliance" onload_delay="90" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P1" id="FileHandle_closeNonBlocking">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_closeNonBlocking.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileHandle" element_type="method" element_name="closeNonBlocking" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileHandle::closeNonBlocking() method throws exception when errorCallback is invalid" type="compliance" onload_delay="90" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileHandle_closeNonBlocking_errorCallback_invalid_cb">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_closeNonBlocking_errorCallback_invalid_cb.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileHandle" element_type="method" element_name="closeNonBlocking" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileHandle::closeNonBlocking() method exists" type="compliance" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P0" id="FileHandle_closeNonBlocking_exist">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_closeNonBlocking_exist.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileHandle" element_type="method" element_name="closeNonBlocking" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileHandle::closeNonBlocking() method throws exception for wrong type of onerror" type="compliance" onload_delay="90" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileHandle_closeNonBlocking_onerror_TypeMismatch">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_closeNonBlocking_onerror_TypeMismatch.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileHandle" element_type="method" element_name="closeNonBlocking" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileHandle::closeNonBlocking() method throws exception for wrong type of onsuccess" type="compliance" onload_delay="90" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileHandle_closeNonBlocking_onsuccess_TypeMismatch">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_closeNonBlocking_onsuccess_TypeMismatch.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileHandle" element_type="method" element_name="closeNonBlocking" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileHandle::closeNonBlocking() method throws exception when successCallback is invalid" type="compliance" onload_delay="90" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileHandle_closeNonBlocking_successCallback_invalid_cb">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_closeNonBlocking_successCallback_invalid_cb.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileHandle" element_type="method" element_name="closeNonBlocking" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileHandle::closeNonBlocking() method works properly with onerror" type="compliance" onload_delay="90" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P1" id="FileHandle_closeNonBlocking_with_onerror">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_closeNonBlocking_with_onerror.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileHandle" element_type="method" element_name="closeNonBlocking" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileHandle::close() method exists" type="compliance" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P0" id="FileHandle_close_exist">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_close_exist.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileHandle" element_type="method" element_name="close" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check using FileHandle::close() method with extra argument" type="compliance" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P1" id="FileHandle_close_extra_argument">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_close_extra_argument.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileHandle" element_type="method" element_name="close" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileHandle::flush() method works properly" type="compliance" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P1" id="FileHandle_flush">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_flush.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileHandle" element_type="method" element_name="flush" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileHandle::flushNonBlocking() method works properly" type="compliance" onload_delay="90" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P1" id="FileHandle_flushNonBlocking">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_flushNonBlocking.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileHandle" element_type="method" element_name="flushNonBlocking" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileHandle::flushNonBlocking() method throws exception when errorCallback is invalid" type="compliance" onload_delay="90" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileHandle_flushNonBlocking_errorCallback_invalid_cb">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_flushNonBlocking_errorCallback_invalid_cb.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileHandle" element_type="method" element_name="flushNonBlocking" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if errorcallback of FileHandle::flushNonBlocking() method can be invoked if input/output error occurs" type="compliance" onload_delay="90" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileHandle_flushNonBlocking_errorCallback_invoked_IOError">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_flushNonBlocking_errorCallback_invoked_IOError.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileHandle" element_type="method" element_name="flushNonBlocking" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileHandle::flushNonBlocking() method exists" type="compliance" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P0" id="FileHandle_flushNonBlocking_exist">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_flushNonBlocking_exist.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileHandle" element_type="method" element_name="flushNonBlocking" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileHandle::flushNonBlocking() method throws exception for wrong type of onerror" type="compliance" onload_delay="90" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileHandle_flushNonBlocking_onerror_TypeMismatch">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_flushNonBlocking_onerror_TypeMismatch.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileHandle" element_type="method" element_name="flushNonBlocking" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileHandle::flushNonBlocking() method throws exception for wrong type of onsuccess" type="compliance" onload_delay="90" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileHandle_flushNonBlocking_onsuccess_TypeMismatch">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_flushNonBlocking_onsuccess_TypeMismatch.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileHandle" element_type="method" element_name="flushNonBlocking" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileHandle::flushNonBlocking() method throws exception when successCallback is invalid" type="compliance" onload_delay="90" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileHandle_flushNonBlocking_successCallback_invalid_cb">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_flushNonBlocking_successCallback_invalid_cb.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileHandle" element_type="method" element_name="flushNonBlocking" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileHandle::flushNonBlocking() method works properly with onerror" type="compliance" onload_delay="90" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P1" id="FileHandle_flushNonBlocking_with_onerror">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_flushNonBlocking_with_onerror.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileHandle" element_type="method" element_name="flushNonBlocking" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileHandle::flush() method exists" type="compliance" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P0" id="FileHandle_flush_exist">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_flush_exist.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileHandle" element_type="method" element_name="flush" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check using FileHandle::flush() method with extra argument" type="compliance" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P1" id="FileHandle_flush_extra_argument">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_flush_extra_argument.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileHandle" element_type="method" element_name="flush" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Interface FileHandle should not be accessible" type="compliance" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P3" id="FileHandle_notexist">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_notexist.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileHandle" usage="true" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileHandle::path attribute exists, has type DOMString and is readonly" type="compliance" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P1" id="FileHandle_path_attribute">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_path_attribute.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileHandle" element_type="attribute" element_name="path" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileHandle::readBlob() method works properly" type="compliance" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P1" id="FileHandle_readBlob">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_readBlob.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileHandle" element_type="method" element_name="readBlob" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileHandle::readBlobNonBlocking() method works properly" type="compliance" onload_delay="90" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P1" id="FileHandle_readBlobNonBlocking">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_readBlobNonBlocking.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileHandle" element_type="method" element_name="readBlobNonBlocking" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileHandle::readBlobNonBlocking() method with invalid count throws InvalidValuesError" type="compliance" onload_delay="90" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileHandle_readBlobNonBlocking_InvalidValuesError">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_readBlobNonBlocking_InvalidValuesError.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileHandle" element_type="method" element_name="readBlobNonBlocking" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileHandle::readBlobNonBlocking() method throws exception when errorCallback is invalid" type="compliance" onload_delay="90" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileHandle_readBlobNonBlocking_errorCallback_invalid_cb">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_readBlobNonBlocking_errorCallback_invalid_cb.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileHandle" element_type="method" element_name="readBlobNonBlocking" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if errorcallback of FileHandle::readBlobNonBlocking() method can be invoked if input/output error occurs" type="compliance" onload_delay="90" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileHandle_readBlobNonBlocking_errorCallback_invoked_IOError">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_readBlobNonBlocking_errorCallback_invoked_IOError.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileHandle" element_type="method" element_name="readBlobNonBlocking" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileHandle::readBlobNonBlocking() method exists" type="compliance" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P0" id="FileHandle_readBlobNonBlocking_exist">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_readBlobNonBlocking_exist.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileHandle" element_type="method" element_name="readBlobNonBlocking" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileHandle::readBlobNonBlocking() method throws exception for wrong type of onerror" type="compliance" onload_delay="90" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileHandle_readBlobNonBlocking_onerror_TypeMismatch">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_readBlobNonBlocking_onerror_TypeMismatch.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileHandle" element_type="method" element_name="readBlobNonBlocking" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileHandle::readBlobNonBlocking() method throws exception for wrong type of onsuccess" type="compliance" onload_delay="90" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileHandle_readBlobNonBlocking_onsuccess_TypeMismatch">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_readBlobNonBlocking_onsuccess_TypeMismatch.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileHandle" element_type="method" element_name="readBlobNonBlocking" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileHandle::readBlobNonBlocking() method throws exception when successCallback is invalid" type="compliance" onload_delay="90" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileHandle_readBlobNonBlocking_successCallback_invalid_cb">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_readBlobNonBlocking_successCallback_invalid_cb.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileHandle" element_type="method" element_name="readBlobNonBlocking" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileHandle::readBlobNonBlocking() method works properly with inputEncoding" type="compliance" onload_delay="90" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P1" id="FileHandle_readBlobNonBlocking_with_size">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_readBlobNonBlocking_with_size.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileHandle" element_type="method" element_name="readBlobNonBlocking" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileHandle::readBlob() method with file handle closed throws IOError" type="compliance" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileHandle_readBlob_IOError">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_readBlob_IOError.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileHandle" element_type="method" element_name="readBlob" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileHandle::readBlob() method with invalid count throws InvalidValuesError" type="compliance" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileHandle_readBlob_InvalidValuesError">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_readBlob_InvalidValuesError.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileHandle" element_type="method" element_name="readBlob" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileHandle::readBlob() method exists" type="compliance" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P0" id="FileHandle_readBlob_exist">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_readBlob_exist.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileHandle" element_type="method" element_name="readBlob" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileHandle::readBlob() method works properly with size" type="compliance" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P1" id="FileHandle_readBlob_with_size">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_readBlob_with_size.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileHandle" element_type="method" element_name="readBlob" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileHandle::readData() method works properly" type="compliance" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P1" id="FileHandle_readData">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_readData.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileHandle" element_type="method" element_name="readData" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileHandle::readDataNonBlocking() method works properly" type="compliance" onload_delay="90" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P1" id="FileHandle_readDataNonBlocking">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_readDataNonBlocking.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileHandle" element_type="method" element_name="readDataNonBlocking" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileHandle::readDataNonBlocking() method with invalid size throws InvalidValuesError" type="compliance" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileHandle_readDataNonBlocking_InvalidValuesError">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_readDataNonBlocking_InvalidValuesError.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileHandle" element_type="method" element_name="readDataNonBlocking" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileHandle::readDataNonBlocking() method throws exception when errorCallback is invalid" type="compliance" onload_delay="90" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileHandle_readDataNonBlocking_errorCallback_invalid_cb">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_readDataNonBlocking_errorCallback_invalid_cb.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileHandle" element_type="method" element_name="readDataNonBlocking" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if errorcallback of FileHandle::readDataNonBlocking() method can be invoked with file handle occurs error" type="compliance" onload_delay="90" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileHandle_readDataNonBlocking_errorCallback_invoked">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_readDataNonBlocking_errorCallback_invoked.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileHandle" element_type="method" element_name="readDataNonBlocking" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileHandle::readDataNonBlocking() method exists" type="compliance" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P0" id="FileHandle_readDataNonBlocking_exist">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_readDataNonBlocking_exist.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileHandle" element_type="method" element_name="readDataNonBlocking" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileHandle::readDataNonBlocking() method throws exception for wrong type of onerror" type="compliance" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileHandle_readDataNonBlocking_onerror_TypeMismatch">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_readDataNonBlocking_onerror_TypeMismatch.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileHandle" element_type="method" element_name="readDataNonBlocking" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileHandle::readDataNonBlocking() method throws exception for wrong type of onsuccess" type="compliance" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileHandle_readDataNonBlocking_onsuccess_TypeMismatch">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_readDataNonBlocking_onsuccess_TypeMismatch.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileHandle" element_type="method" element_name="readDataNonBlocking" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileHandle::readDataNonBlocking() method throws exception when successCallback is invalid" type="compliance" onload_delay="90" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileHandle_readDataNonBlocking_successCallback_invalid_cb">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_readDataNonBlocking_successCallback_invalid_cb.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileHandle" element_type="method" element_name="readDataNonBlocking" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileHandle::readDataNonBlocking() method works properly with size" type="compliance" onload_delay="90" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P1" id="FileHandle_readDataNonBlocking_with_size">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_readDataNonBlocking_with_size.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileHandle" element_type="method" element_name="readDataNonBlocking" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileHandle::readData() method with file handle closed throws IOError" type="compliance" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileHandle_readData_IOError">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_readData_IOError.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileHandle" element_type="method" element_name="readData" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileHandle::readData() method with invalid size throws InvalidValuesError" type="compliance" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileHandle_readData_InvalidValuesError">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_readData_InvalidValuesError.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileHandle" element_type="method" element_name="readData" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileHandle::readData() method exists" type="compliance" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P0" id="FileHandle_readData_exist">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_readData_exist.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileHandle" element_type="method" element_name="readData" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileHandle::readData() method works properly with size" type="compliance" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P1" id="FileHandle_readData_with_size">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_readData_with_size.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileHandle" element_type="method" element_name="readData" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileHandle::readString() method works properly" type="compliance" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P1" id="FileHandle_readString">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_readString.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileHandle" element_type="method" element_name="readString" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileHandle::readStringNonBlocking() method works properly" type="compliance" onload_delay="90" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P1" id="FileHandle_readStringNonBlocking">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_readStringNonBlocking.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileHandle" element_type="method" element_name="readStringNonBlocking" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileHandle::readStringNonBlocking() method throws exception when errorCallback is invalid" type="compliance" onload_delay="90" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileHandle_readStringNonBlocking_errorCallback_invalid_cb">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_readStringNonBlocking_errorCallback_invalid_cb.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileHandle" element_type="method" element_name="readStringNonBlocking" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if errorcallback of FileHandle::readStringNonBlocking() method can be invoked if input/output error occurs" type="compliance" onload_delay="90" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileHandle_readStringNonBlocking_errorCallback_invoked_IOError">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_readStringNonBlocking_errorCallback_invoked_IOError.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileHandle" element_type="method" element_name="readStringNonBlocking" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileHandle::readStringNonBlocking() method exists" type="compliance" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P0" id="FileHandle_readStringNonBlocking_exist">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_readStringNonBlocking_exist.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileHandle" element_type="method" element_name="readStringNonBlocking" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileHandle::readStringNonBlocking() method with invalid count throws InvalidValuesError" type="compliance" onload_delay="90" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileHandle_readStringNonBlocking_InvalidValuesError">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_readStringNonBlocking_InvalidValuesError.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileHandle" element_type="method" element_name="readStringNonBlocking" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if readStringNonBlocking() method with not-supported encoding throws NotSupportedError" type="compliance" onload_delay="90" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileHandle_readStringNonBlocking_NotSupportedError">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_readStringNonBlocking_NotSupportedError.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileHandle" element_type="method" element_name="readStringNonBlocking" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileHandle::readStringNonBlocking() method throws exception for wrong type of onerror" type="compliance" onload_delay="90" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileHandle_readStringNonBlocking_onerror_TypeMismatch">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_readStringNonBlocking_onerror_TypeMismatch.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileHandle" element_type="method" element_name="readStringNonBlocking" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileHandle::readStringNonBlocking() method throws exception for wrong type of onsuccess" type="compliance" onload_delay="90" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileHandle_readStringNonBlocking_onsuccess_TypeMismatch">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_readStringNonBlocking_onsuccess_TypeMismatch.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileHandle" element_type="method" element_name="readStringNonBlocking" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileHandle::readStringNonBlocking() method throws exception when successCallback is invalid" type="compliance" onload_delay="90" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileHandle_readStringNonBlocking_successCallback_invalid_cb">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_readStringNonBlocking_successCallback_invalid_cb.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileHandle" element_type="method" element_name="readStringNonBlocking" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileHandle::readStringNonBlocking() method works properly with inputEncoding" type="compliance" onload_delay="90" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P1" id="FileHandle_readStringNonBlocking_with_inputEncoding">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_readStringNonBlocking_with_inputEncoding.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileHandle" element_type="method" element_name="readStringNonBlocking" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileHandle::readString() method with file handle closed throws IOError" type="compliance" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileHandle_readString_IOError">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_readString_IOError.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileHandle" element_type="method" element_name="readString" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileHandle::readString() method with invalid count throws InvalidValuesError" type="compliance" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileHandle_readString_InvalidValuesError">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_readString_InvalidValuesError.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileHandle" element_type="method" element_name="readString" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileHandle::readString() method with invalid encoding throws NotSupportedError" type="compliance" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileHandle_readString_NotSupportedError">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_readString_NotSupportedError.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileHandle" element_type="method" element_name="readString" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileHandle::readString() method exists" type="compliance" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P0" id="FileHandle_readString_exist">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_readString_exist.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileHandle" element_type="method" element_name="readString" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileHandle::readString() method works properly with inputEncoding" type="compliance" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P1" id="FileHandle_readString_with_inputEncoding">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_readString_with_inputEncoding.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileHandle" element_type="method" element_name="readString" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileHandle::seek() method works properly" type="compliance" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P1" id="FileHandle_seek">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_seek.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileHandle" element_type="method" element_name="seek" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileHandle::seekNonBlocking() method works properly" type="compliance" onload_delay="90" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P1" id="FileHandle_seekNonBlocking">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_seekNonBlocking.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileHandle" element_type="method" element_name="seekNonBlocking" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileHandle::seekNonBlocking() method throws exception when errorCallback is invalid" type="compliance" onload_delay="90" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileHandle_seekNonBlocking_errorCallback_invalid_cb">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_seekNonBlocking_errorCallback_invalid_cb.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileHandle" element_type="method" element_name="seekNonBlocking" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if errorcallback of FileHandle::seekNonBlocking() method can be invoked with file handle occurs error" type="compliance" onload_delay="90" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileHandle_seekNonBlocking_errorCallback_invoked">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_seekNonBlocking_errorCallback_invoked.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileHandle" element_type="method" element_name="seekNonBlocking" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileHandle::seekNonBlocking() method exists" type="compliance" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P0" id="FileHandle_seekNonBlocking_exist">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_seekNonBlocking_exist.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileHandle" element_type="method" element_name="seekNonBlocking" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileHandle::seekNonBlocking() method throws exception for wrong type of onerror" type="compliance" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileHandle_seekNonBlocking_onerror_TypeMismatch">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_seekNonBlocking_onerror_TypeMismatch.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileHandle" element_type="method" element_name="seekNonBlocking" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileHandle::seekNonBlocking() method throws exception for wrong type of onsuccess" type="compliance" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileHandle_seekNonBlocking_onsuccess_TypeMismatch">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_seekNonBlocking_onsuccess_TypeMismatch.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileHandle" element_type="method" element_name="seekNonBlocking" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileHandle::seekNonBlocking() method throws exception when successCallback is invalid" type="compliance" onload_delay="90" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileHandle_seekNonBlocking_successCallback_invalid_cb">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_seekNonBlocking_successCallback_invalid_cb.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileHandle" element_type="method" element_name="seekNonBlocking" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileHandle::seekNonBlocking() method works properly with BaseSeekPosition whence" type="compliance" onload_delay="90" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P1" id="FileHandle_seekNonBlocking_with_whence">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_seekNonBlocking_with_whence.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileHandle" element_type="method" element_name="seekNonBlocking" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileHandle::seek() method with file handle closed throws IOError" type="compliance" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileHandle_seek_IOError">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_seek_IOError.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileHandle" element_type="method" element_name="seek" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileHandle::seek() method exists" type="compliance" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P0" id="FileHandle_seek_exist">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_seek_exist.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileHandle" element_type="method" element_name="seek" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileHandle::seek() method works properly with BaseSeekPosition whence" type="compliance" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P1" id="FileHandle_seek_with_whence">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_seek_with_whence.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileHandle" element_type="method" element_name="seek" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileHandle::sync() method works properly" type="compliance" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P1" id="FileHandle_sync">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_sync.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileHandle" element_type="method" element_name="sync" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileHandle::syncNonBlocking() method works properly" type="compliance" onload_delay="90" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P1" id="FileHandle_syncNonBlocking">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_syncNonBlocking.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileHandle" element_type="method" element_name="syncNonBlocking" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileHandle::syncNonBlocking() method throws exception when errorCallback is invalid" type="compliance" onload_delay="90" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileHandle_syncNonBlocking_errorCallback_invalid_cb">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_syncNonBlocking_errorCallback_invalid_cb.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileHandle" element_type="method" element_name="syncNonBlocking" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if errorcallback of FileHandle::syncNonBlocking() method can be invoked with file handle occurs error" type="compliance" onload_delay="90" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileHandle_syncNonBlocking_errorCallback_invoked">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_syncNonBlocking_errorCallback_invoked.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileHandle" element_type="method" element_name="syncNonBlocking" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileHandle::syncNonBlocking() method exists" type="compliance" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P0" id="FileHandle_syncNonBlocking_exist">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_syncNonBlocking_exist.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileHandle" element_type="method" element_name="syncNonBlocking" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileHandle::syncNonBlocking() method throws exception for wrong type of onerror" type="compliance" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileHandle_syncNonBlocking_onerror_TypeMismatch">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_syncNonBlocking_onerror_TypeMismatch.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileHandle" element_type="method" element_name="syncNonBlocking" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileHandle::syncNonBlocking() method throws exception for wrong type of onsuccess" type="compliance" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileHandle_syncNonBlocking_onsuccess_TypeMismatch">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_syncNonBlocking_onsuccess_TypeMismatch.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileHandle" element_type="method" element_name="syncNonBlocking" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileHandle::syncNonBlocking() method throws exception when successCallback is invalid" type="compliance" onload_delay="90" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileHandle_syncNonBlocking_successCallback_invalid_cb">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_syncNonBlocking_successCallback_invalid_cb.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileHandle" element_type="method" element_name="syncNonBlocking" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileHandle::syncNonBlocking() method works properly with onerror" type="compliance" onload_delay="90" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P1" id="FileHandle_syncNonBlocking_with_onerror">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_syncNonBlocking_with_onerror.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileHandle" element_type="method" element_name="syncNonBlocking" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileHandle::sync() method exists" type="compliance" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P0" id="FileHandle_sync_exist">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_sync_exist.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileHandle" element_type="method" element_name="sync" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check using FileHandle::sync() method with extra argument" type="compliance" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P1" id="FileHandle_sync_extra_argument">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_sync_extra_argument.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileHandle" element_type="method" element_name="sync" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileHandle::writeBlob() method works properly" type="compliance" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P1" id="FileHandle_writeBlob">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_writeBlob.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileHandle" element_type="method" element_name="writeBlob" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileHandle::writeBlobNonBlocking() method works properly" type="compliance" onload_delay="90" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P1" id="FileHandle_writeBlobNonBlocking">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_writeBlobNonBlocking.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileHandle" element_type="method" element_name="writeBlobNonBlocking" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileHandle:writeBlobNonBlocking() throws exception when blob is incorrect" type="compliance" onload_delay="90" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileHandle_writeBlobNonBlocking_blob_TypeMismatch">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_writeBlobNonBlocking_blob_TypeMismatch.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileHandle" element_type="method" element_name="writeBlobNonBlocking" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileHandle::writeBlobNonBlocking() method throws exception when errorCallback is invalid" type="compliance" onload_delay="90" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileHandle_writeBlobNonBlocking_errorCallback_invalid_cb">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_writeBlobNonBlocking_errorCallback_invalid_cb.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileHandle" element_type="method" element_name="writeBlobNonBlocking" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if errorcallback of FileHandle::writeBlobNonBlocking() method can be invoked if input/output error occurs" type="compliance" onload_delay="90" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileHandle_writeBlobNonBlocking_errorCallback_invoked_IOError">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_writeBlobNonBlocking_errorCallback_invoked_IOError.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileHandle" element_type="method" element_name="writeBlobNonBlocking" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileHandle::writeBlobNonBlocking() method exists" type="compliance" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P0" id="FileHandle_writeBlobNonBlocking_exist">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_writeBlobNonBlocking_exist.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileHandle" element_type="method" element_name="writeBlobNonBlocking" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileHandle::writeBlobNonBlocking() method with missing mandatory argument throws exception" type="compliance" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileHandle_writeBlobNonBlocking_misarg">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_writeBlobNonBlocking_misarg.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileHandle" element_type="method" element_name="writeBlobNonBlocking" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileHandle::writeBlobNonBlocking() method throws exception for wrong type of onerror" type="compliance" onload_delay="90" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileHandle_writeBlobNonBlocking_onerror_TypeMismatch">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_writeBlobNonBlocking_onerror_TypeMismatch.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileHandle" element_type="method" element_name="writeBlobNonBlocking" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileHandle::writeBlobNonBlocking() method throws exception for wrong type of onsuccess" type="compliance" onload_delay="90" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileHandle_writeBlobNonBlocking_onsuccess_TypeMismatch">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_writeBlobNonBlocking_onsuccess_TypeMismatch.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileHandle" element_type="method" element_name="writeBlobNonBlocking" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileHandle::writeBlobNonBlocking() method throws exception when successCallback is invalid" type="compliance" onload_delay="90" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileHandle_writeBlobNonBlocking_successCallback_invalid_cb">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_writeBlobNonBlocking_successCallback_invalid_cb.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileHandle" element_type="method" element_name="writeBlobNonBlocking" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileHandle::writeBlobNonBlocking() method works properly with onerror" type="compliance" onload_delay="90" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P1" id="FileHandle_writeBlobNonBlocking_with_onerror">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_writeBlobNonBlocking_with_onerror.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileHandle" element_type="method" element_name="writeBlobNonBlocking" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileHandle::writeBlob() method with file handle closed throws IOError" type="compliance" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileHandle_writeBlob_IOError">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_writeBlob_IOError.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileHandle" element_type="method" element_name="writeBlob" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileHandle:writeBlob() throws exception when blob is incorrect" type="compliance" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileHandle_writeBlob_blob_TypeMismatch">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_writeBlob_blob_TypeMismatch.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileHandle" element_type="method" element_name="writeBlob" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileHandle::writeBlob() method exists" type="compliance" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P0" id="FileHandle_writeBlob_exist">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_writeBlob_exist.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileHandle" element_type="method" element_name="writeBlob" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileHandle::writeBlob() method with missing mandatory argument throws exception" type="compliance" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileHandle_writeBlob_misarg">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_writeBlob_misarg.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileHandle" element_type="method" element_name="writeBlob" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileHandle::writeData() method works properly" type="compliance" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P1" id="FileHandle_writeData">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_writeData.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileHandle" element_type="method" element_name="writeData" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileHandle::writeDataNonBlocking() method works properly" type="compliance" onload_delay="90" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P1" id="FileHandle_writeDataNonBlocking">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_writeDataNonBlocking.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileHandle" element_type="method" element_name="writeDataNonBlocking" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileHandle::writeDataNonBlocking() method throws exception when errorCallback is invalid" type="compliance" onload_delay="90" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileHandle_writeDataNonBlocking_errorCallback_invalid_cb">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_writeDataNonBlocking_errorCallback_invalid_cb.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileHandle" element_type="method" element_name="writeDataNonBlocking" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if errorcallback of FileHandle::writeDataNonBlocking() method can be invoked with file handle occurs error" type="compliance" onload_delay="90" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileHandle_writeDataNonBlocking_errorCallback_invoked">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_writeDataNonBlocking_errorCallback_invoked.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileHandle" element_type="method" element_name="writeDataNonBlocking" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileHandle::writeDataNonBlocking() method exists" type="compliance" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P0" id="FileHandle_writeDataNonBlocking_exist">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_writeDataNonBlocking_exist.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileHandle" element_type="method" element_name="writeDataNonBlocking" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileHandle::writeDataNonBlocking() method with missing mandatory argument throws exception" type="compliance" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileHandle_writeDataNonBlocking_misarg">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_writeDataNonBlocking_misarg.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileHandle" element_type="method" element_name="writeDataNonBlocking" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileHandle::writeDataNonBlocking() method throws exception for wrong type of onerror" type="compliance" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileHandle_writeDataNonBlocking_onerror_TypeMismatch">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_writeDataNonBlocking_onerror_TypeMismatch.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileHandle" element_type="method" element_name="writeDataNonBlocking" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileHandle::writeDataNonBlocking() method throws exception for wrong type of onsuccess" type="compliance" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileHandle_writeDataNonBlocking_onsuccess_TypeMismatch">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_writeDataNonBlocking_onsuccess_TypeMismatch.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileHandle" element_type="method" element_name="writeDataNonBlocking" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileHandle::writeDataNonBlocking() method throws exception when successCallback is invalid" type="compliance" onload_delay="90" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileHandle_writeDataNonBlocking_successCallback_invalid_cb">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_writeDataNonBlocking_successCallback_invalid_cb.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileHandle" element_type="method" element_name="writeDataNonBlocking" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileHandle::writeDataNonBlocking() method works properly with onerror" type="compliance" onload_delay="90" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P1" id="FileHandle_writeDataNonBlocking_with_onerror">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_writeDataNonBlocking_with_onerror.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileHandle" element_type="method" element_name="writeDataNonBlocking" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileHandle::writeData() method with file handle closed throws IOError" type="compliance" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileHandle_writeData_IOError">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_writeData_IOError.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileHandle" element_type="method" element_name="writeData" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileHandle:writeData() throws exception when data type is incorrect" type="compliance" onload_delay="90" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileHandle_writeData_data_TypeMismatch">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_writeData_data_TypeMismatch.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileHandle" element_type="method" element_name="writeData" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileHandle::writeData() method exists" type="compliance" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P0" id="FileHandle_writeData_exist">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_writeData_exist.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileHandle" element_type="method" element_name="writeData" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileHandle::writeData() method with missing mandatory argument throws exception" type="compliance" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileHandle_writeData_misarg">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_writeData_misarg.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileHandle" element_type="method" element_name="writeData" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileHandle::writeString() method works properly" type="compliance" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P1" id="FileHandle_writeString">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_writeString.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileHandle" element_type="method" element_name="writeString" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileHandle::writeStringNonBlocking() method works properly" type="compliance" onload_delay="90" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P1" id="FileHandle_writeStringNonBlocking">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_writeStringNonBlocking.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileHandle" element_type="method" element_name="writeStringNonBlocking" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileHandle::writeStringNonBlocking() method throws exception when errorCallback is invalid" type="compliance" onload_delay="90" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileHandle_writeStringNonBlocking_errorCallback_invalid_cb">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_writeStringNonBlocking_errorCallback_invalid_cb.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileHandle" element_type="method" element_name="writeStringNonBlocking" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if errorcallback of FileHandle::writeStringNonBlocking() method can be invoked if input/output error occurs" type="compliance" onload_delay="90" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileHandle_writeStringNonBlocking_errorCallback_invoked_IOError">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_writeStringNonBlocking_errorCallback_invoked_IOError.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileHandle" element_type="method" element_name="writeStringNonBlocking" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileHandle::writeStringNonBlocking() method exists" type="compliance" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P0" id="FileHandle_writeStringNonBlocking_exist">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_writeStringNonBlocking_exist.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileHandle" element_type="method" element_name="writeStringNonBlocking" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if writeStringNonBlocking() method with not-supported encoding throws NotSupportedError" type="compliance" onload_delay="90" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileHandle_writeStringNonBlocking_NotSupportedError">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_writeStringNonBlocking_NotSupportedError.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileHandle" element_type="method" element_name="writeStringNonBlocking" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileHandle::writeStringNonBlocking() method throws exception for wrong type of onerror" type="compliance" onload_delay="90" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileHandle_writeStringNonBlocking_onerror_TypeMismatch">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_writeStringNonBlocking_onerror_TypeMismatch.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileHandle" element_type="method" element_name="writeStringNonBlocking" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileHandle::writeStringNonBlocking() method throws exception for wrong type of onsuccess" type="compliance" onload_delay="90" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileHandle_writeStringNonBlocking_onsuccess_TypeMismatch">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_writeStringNonBlocking_onsuccess_TypeMismatch.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileHandle" element_type="method" element_name="writeStringNonBlocking" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileHandle::writeStringNonBlocking() method throws exception when successCallback is invalid" type="compliance" onload_delay="90" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileHandle_writeStringNonBlocking_successCallback_invalid_cb">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_writeStringNonBlocking_successCallback_invalid_cb.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileHandle" element_type="method" element_name="writeStringNonBlocking" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileHandle::writeStringNonBlocking() method works properly with outputEncoding" type="compliance" onload_delay="90" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P1" id="FileHandle_writeStringNonBlocking_with_outputEncoding">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_writeStringNonBlocking_with_outputEncoding.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileHandle" element_type="method" element_name="writeStringNonBlocking" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileHandle::writeString() method with file handle closed throws IOError" type="compliance" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileHandle_writeString_IOError">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_writeString_IOError.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileHandle" element_type="method" element_name="writeString" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileHandle::writeString() method with invalid encoding throws NotSupportedError" type="compliance" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileHandle_writeString_NotSupportedError">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_writeString_NotSupportedError.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileHandle" element_type="method" element_name="writeString" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileHandle::writeString() method exists" type="compliance" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P0" id="FileHandle_writeString_exist">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_writeString_exist.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileHandle" element_type="method" element_name="writeString" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileHandle::writeString() method works properly with outputEncoding" type="compliance" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P1" id="FileHandle_writeString_with_outputEncoding">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_writeString_with_outputEncoding.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileHandle" element_type="method" element_name="writeString" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::copyDirectory() method works properly" type="compliance" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P1" id="FileSystemManager_copyDirectory">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_copyDirectory.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileSystemManager" element_type="method" element_name="copyDirectory" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::copyDirectory() method with invalid path throws InvalidValuesError" type="compliance" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileSystemManager_copyDirectory_InvalidValuesError">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_copyDirectory_InvalidValuesError.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileSystemManager" element_type="method" element_name="copyDirectory" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::copyDirectory() method throws exception when errorCallback is invalid" type="compliance" onload_delay="90" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileSystemManager_copyDirectory_errorCallback_invalid_cb">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_copyDirectory_errorCallback_invalid_cb.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileSystemManager" element_type="method" element_name="copyDirectory" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::copyDirectory() method throws NotFoundError when path not exists" type="compliance" onload_delay="90" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileSystemManager_copyDirectory_errorCallback_invoked_NotFoundError">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_copyDirectory_errorCallback_invoked_NotFoundError.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileSystemManager" element_type="method" element_name="copyDirectory" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::copyDirectory() method exists" type="compliance" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P0" id="FileSystemManager_copyDirectory_exist">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_copyDirectory_exist.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileSystemManager" element_type="method" element_name="copyDirectory" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::copyDirectory() method with missing mandatory argument throws exception" type="compliance" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileSystemManager_copyDirectory_misarg">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_copyDirectory_misarg.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileSystemManager" element_type="method" element_name="copyDirectory" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::copyDirectory() method throws exception for wrong type of onerror" type="compliance" onload_delay="90" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileSystemManager_copyDirectory_onerror_TypeMismatch">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_copyDirectory_onerror_TypeMismatch.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileSystemManager" element_type="method" element_name="copyDirectory" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::copyDirectory() method throws exception for wrong type of onsuccess" type="compliance" onload_delay="90" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileSystemManager_copyDirectory_onsuccess_TypeMismatch">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_copyDirectory_onsuccess_TypeMismatch.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileSystemManager" element_type="method" element_name="copyDirectory" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::copyDirectory() method throws exception when successCallback is invalid" type="compliance" onload_delay="90" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileSystemManager_copyDirectory_successCallback_invalid_cb">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_copyDirectory_successCallback_invalid_cb.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileSystemManager" element_type="method" element_name="copyDirectory" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::copyDirectory() method works properly with errorCallback" type="compliance" onload_delay="90" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P1" id="FileSystemManager_copyDirectory_with_errorCallback">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_copyDirectory_with_errorCallback.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileSystemManager" element_type="method" element_name="copyDirectory" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::copyFile() method works properly" type="compliance" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P1" id="FileSystemManager_copyFile">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_copyFile.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileSystemManager" element_type="method" element_name="copyFile" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::copyFile() method with invalid path throws InvalidValuesError" type="compliance" onload_delay="90" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileSystemManager_copyFile_InvalidValuesError">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_copyFile_InvalidValuesError.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileSystemManager" element_type="method" element_name="copyFile" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::copyFile() method throws exception when errorCallback is invalid" type="compliance" onload_delay="90" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileSystemManager_copyFile_errorCallback_invalid_cb">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_copyFile_errorCallback_invalid_cb.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileSystemManager" element_type="method" element_name="copyFile" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::copyFile() method throws NotFoundError when path not exists" type="compliance" onload_delay="90" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileSystemManager_copyFile_errorCallback_invoked_NotFoundError">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_copyFile_errorCallback_invoked_NotFoundError.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileSystemManager" element_type="method" element_name="copyFile" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::copyFile() method exists" type="compliance" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P0" id="FileSystemManager_copyFile_exist">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_copyFile_exist.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileSystemManager" element_type="method" element_name="copyFile" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::copyFile() method with missing mandatory argument throws exception" type="compliance" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileSystemManager_copyFile_misarg">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_copyFile_misarg.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileSystemManager" element_type="method" element_name="copyFile" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::copyFile() method throws exception for wrong type of onerror" type="compliance" onload_delay="90" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileSystemManager_copyFile_onerror_TypeMismatch">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_copyFile_onerror_TypeMismatch.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileSystemManager" element_type="method" element_name="copyFile" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::copyFile() method throws exception for wrong type of onsuccess" type="compliance" onload_delay="90" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileSystemManager_copyFile_onsuccess_TypeMismatch">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_copyFile_onsuccess_TypeMismatch.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileSystemManager" element_type="method" element_name="copyFile" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::copyFile() method throws exception when successCallback is invalid" type="compliance" onload_delay="90" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileSystemManager_copyFile_successCallback_invalid_cb">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_copyFile_successCallback_invalid_cb.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileSystemManager" element_type="method" element_name="copyFile" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::copyFile() method works properly with errorCallback" type="compliance" onload_delay="90" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P1" id="FileSystemManager_copyFile_with_errorCallback">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_copyFile_with_errorCallback.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileSystemManager" element_type="method" element_name="copyFile" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::createDirectory() method works properly" type="compliance" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P1" id="FileSystemManager_createDirectory">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_createDirectory.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileSystemManager" element_type="method" element_name="createDirectory" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::createDirectory() method with invalid path throws InvalidValuesError" type="compliance" onload_delay="90" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileSystemManager_createDirectory_InvalidValuesError">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_createDirectory_InvalidValuesError.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileSystemManager" element_type="method" element_name="createDirectory" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::createDirectory() method throws exception when errorCallback is invalid" type="compliance" onload_delay="90" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileSystemManager_createDirectory_errorCallback_invalid_cb">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_createDirectory_errorCallback_invalid_cb.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileSystemManager" element_type="method" element_name="createDirectory" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::createDirectory() method throws NotFoundError when path not exists" type="compliance" onload_delay="90" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileSystemManager_createDirectory_errorCallback_invoked_NotFoundError">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_createDirectory_errorCallback_invoked_NotFoundError.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileSystemManager" element_type="method" element_name="createDirectory" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::createDirectory() method exists" type="compliance" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P0" id="FileSystemManager_createDirectory_exist">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_createDirectory_exist.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileSystemManager" element_type="method" element_name="createDirectory" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::createDirectory() method throws exception for wrong type of onerror" type="compliance" onload_delay="90" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileSystemManager_createDirectory_onerror_TypeMismatch">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_createDirectory_onerror_TypeMismatch.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileSystemManager" element_type="method" element_name="createDirectory" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::createDirectory() method throws exception for wrong type of onsuccess" type="compliance" onload_delay="90" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileSystemManager_createDirectory_onsuccess_TypeMismatch">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_createDirectory_onsuccess_TypeMismatch.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileSystemManager" element_type="method" element_name="createDirectory" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::createDirectory() method throws exception when successCallback is invalid" type="compliance" onload_delay="90" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileSystemManager_createDirectory_successCallback_invalid_cb">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_createDirectory_successCallback_invalid_cb.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileSystemManager" element_type="method" element_name="createDirectory" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::createDirectory() method works properly with errorCallback" type="compliance" onload_delay="90" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P1" id="FileSystemManager_createDirectory_with_errorCallback">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_createDirectory_with_errorCallback.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileSystemManager" element_type="method" element_name="createDirectory" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::deleteDirectory() method works properly" type="compliance" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P1" id="FileSystemManager_deleteDirectory">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_deleteDirectory.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileSystemManager" element_type="method" element_name="deleteDirectory" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::deleteDirectory() method with invalid path throws InvalidValuesError" type="compliance" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileSystemManager_deleteDirectory_InvalidValuesError">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_deleteDirectory_InvalidValuesError.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileSystemManager" element_type="method" element_name="deleteDirectory" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::deleteDirectory() method throws exception when errorCallback is invalid" type="compliance" onload_delay="90" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileSystemManager_deleteDirectory_errorCallback_invalid_cb">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_deleteDirectory_errorCallback_invalid_cb.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileSystemManager" element_type="method" element_name="deleteDirectory" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::deleteDirectory() method throws NotFoundError when path not exists" type="compliance" onload_delay="90" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileSystemManager_deleteDirectory_errorCallback_invoked_NotFoundError">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_deleteDirectory_errorCallback_invoked_NotFoundError.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileSystemManager" element_type="method" element_name="deleteDirectory" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::deleteDirectory() method exists" type="compliance" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P0" id="FileSystemManager_deleteDirectory_exist">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_deleteDirectory_exist.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileSystemManager" element_type="method" element_name="deleteDirectory" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::deleteDirectory() method throws exception for wrong type of onerror" type="compliance" onload_delay="90" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileSystemManager_deleteDirectory_onerror_TypeMismatch">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_deleteDirectory_onerror_TypeMismatch.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileSystemManager" element_type="method" element_name="deleteDirectory" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::deleteDirectory() method throws exception for wrong type of onsuccess" type="compliance" onload_delay="90" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileSystemManager_deleteDirectory_onsuccess_TypeMismatch">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_deleteDirectory_onsuccess_TypeMismatch.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileSystemManager" element_type="method" element_name="deleteDirectory" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::deleteDirectory() method throws exception when successCallback is invalid" type="compliance" onload_delay="90" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileSystemManager_deleteDirectory_successCallback_invalid_cb">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_deleteDirectory_successCallback_invalid_cb.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileSystemManager" element_type="method" element_name="deleteDirectory" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::deleteDirectory() method works properly with errorCallback" type="compliance" onload_delay="90" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P1" id="FileSystemManager_deleteDirectory_with_errorCallback">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_deleteDirectory_with_errorCallback.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileSystemManager" element_type="method" element_name="deleteDirectory" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::deleteFile() method works properly with makeParents" type="compliance" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P1" id="FileSystemManager_deleteFile">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_deleteFile.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileSystemManager" element_type="method" element_name="deleteFile" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::deleteFile() method with invalid path throws InvalidValuesError" type="compliance" onload_delay="90" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileSystemManager_deleteFile_InvalidValuesError">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_deleteFile_InvalidValuesError.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileSystemManager" element_type="method" element_name="deleteFile" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::deleteFile() method throws exception when errorCallback is invalid" type="compliance" onload_delay="90" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileSystemManager_deleteFile_errorCallback_invalid_cb">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_deleteFile_errorCallback_invalid_cb.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileSystemManager" element_type="method" element_name="deleteFile" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::deleteFile() method throws NotFoundError when file not exists" type="compliance" onload_delay="90" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileSystemManager_deleteFile_errorCallback_invoked_NotFoundError">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_deleteFile_errorCallback_invoked_NotFoundError.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileSystemManager" element_type="method" element_name="deleteFile" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::deleteFile() method exists" type="compliance" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P0" id="FileSystemManager_deleteFile_exist">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_deleteFile_exist.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileSystemManager" element_type="method" element_name="deleteFile" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::deleteFile() method throws exception for wrong type of onerror" type="compliance" onload_delay="90" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileSystemManager_deleteFile_onerror_TypeMismatch">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_deleteFile_onerror_TypeMismatch.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileSystemManager" element_type="method" element_name="deleteFile" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::deleteFile() method throws exception for wrong type of onsuccess" type="compliance" onload_delay="90" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileSystemManager_deleteFile_with_errorCallback">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_deleteFile_onsuccess_TypeMismatch.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileSystemManager" element_type="method" element_name="deleteFile" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::deleteFile() method throws exception when successCallback is invalid" type="compliance" onload_delay="90" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileSystemManager_deleteFile_successCallback_invalid_cb">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_deleteFile_successCallback_invalid_cb.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileSystemManager" element_type="method" element_name="deleteFile" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::deleteFile() method works properly with errorCallback" type="compliance" onload_delay="90" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P1" id="FileSystemManager_deleteFile_with_errorCallback">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_deleteFile_with_errorCallback.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileSystemManager" element_type="method" element_name="deleteFile" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::getDirName() method works properly" type="compliance" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P1" id="FileSystemManager_getDirName">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_getDirName.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileSystemManager" element_type="method" element_name="getDirName" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::getDirName() method exists" type="compliance" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P0" id="FileSystemManager_getDirName_exist">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_getDirName_exist.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileSystemManager" element_type="method" element_name="getDirName" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::isDirectory() method works properly" type="compliance" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P1" id="FileSystemManager_isDirectory">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_isDirectory.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileSystemManager" element_type="method" element_name="isDirectory" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::isDirectory() method with invalid path throws InvalidValuesError" type="compliance" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileSystemManager_isDirectory_InvalidValuesError">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_isDirectory_InvalidValuesError.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileSystemManager" element_type="method" element_name="isDirectory" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::isDirectory() method throws NotFoundError when path not exists" type="compliance" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileSystemManager_isDirectory_NotFoundError">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_isDirectory_NotFoundError.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileSystemManager" element_type="method" element_name="isDirectory" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::isDirectory() method exists" type="compliance" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P0" id="FileSystemManager_isDirectory_exist">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_isDirectory_exist.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileSystemManager" element_type="method" element_name="isDirectory" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::isDirectory() method with missing mandatory argument throws exception" type="compliance" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileSystemManager_isDirectory_misarg">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_isDirectory_misarg.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileSystemManager" element_type="method" element_name="isDirectory" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::isFile() method works properly" type="compliance" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P1" id="FileSystemManager_isFile">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_isFile.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileSystemManager" element_type="method" element_name="isFile" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::isFile() method with invalid path throws InvalidValuesError" type="compliance" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileSystemManager_isFile_InvalidValuesError">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_isFile_InvalidValuesError.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileSystemManager" element_type="method" element_name="isFile" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::isFile() method throws NotFoundError when file not exists" type="compliance" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileSystemManager_isFile_NotFoundError">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_isFile_NotFoundError.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileSystemManager" element_type="method" element_name="isFile" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::isFile() method exists" type="compliance" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P0" id="FileSystemManager_isFile_exist">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_isFile_exist.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileSystemManager" element_type="method" element_name="isFile" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::isFile() method with missing mandatory argument throws exception" type="compliance" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileSystemManager_isFile_misarg">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_isFile_misarg.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileSystemManager" element_type="method" element_name="isFile" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::listDirectory() method works properly" type="compliance" onload_delay="90" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P1" id="FileSystemManager_listDirectory">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_listDirectory.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileSystemManager" element_type="method" element_name="listDirectory" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::listDirectory() method throws exception when errorCallback is invalid" type="compliance" onload_delay="90" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileSystemManager_listDirectory_errorCallback_invalid_cb">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_listDirectory_errorCallback_invalid_cb.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileSystemManager" element_type="method" element_name="listDirectory" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::listDirectory() method throws NotFoundError when path not exists" type="compliance" onload_delay="90" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileSystemManager_listDirectory_errorCallback_invoked_NotFoundError">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_listDirectory_errorCallback_invoked_NotFoundError.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileSystemManager" element_type="method" element_name="listDirectory" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::listDirectory() method exists" type="compliance" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P0" id="FileSystemManager_listDirectory_exist">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_listDirectory_exist.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileSystemManager" element_type="method" element_name="listDirectory" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::listDirectory() method with invalid path throws InvalidValuesError" type="compliance" onload_delay="90" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileSystemManager_listDirectory_InvalidValuesError">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_listDirectory_InvalidValuesError.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileSystemManager" element_type="method" element_name="listDirectory" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::listDirectory() method with missing mandatory argument throws exception" type="compliance" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileSystemManager_listDirectory_misarg">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_listDirectory_misarg.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileSystemManager" element_type="method" element_name="listDirectory" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::listDirectory() method throws exception for wrong type of onerror" type="compliance" onload_delay="90" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileSystemManager_listDirectory_onerror_TypeMismatch">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_listDirectory_onerror_TypeMismatch.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileSystemManager" element_type="method" element_name="listDirectory" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::listDirectory() method throws exception for wrong type of onsuccess" type="compliance" onload_delay="90" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileSystemManager_listDirectory_onsuccess_TypeMismatch">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_listDirectory_onsuccess_TypeMismatch.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileSystemManager" element_type="method" element_name="listDirectory" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::listDirectory() method throws exception when successCallback is invalid" type="compliance" onload_delay="90" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileSystemManager_listDirectory_successCallback_invalid_cb">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_listDirectory_successCallback_invalid_cb.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileSystemManager" element_type="method" element_name="listDirectory" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::listDirectory() method works properly with filter" type="compliance" onload_delay="90" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P1" id="FileSystemManager_listDirectory_with_filter">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_listDirectory_with_filter.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileSystemManager" element_type="method" element_name="listDirectory" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if attribute maxNameLength of FileSystemManager exists, has type long and is readonly" type="compliance" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P1" id="FileSystemManager_maxNameLength_attribute">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_maxNameLength_attribute.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileSystemManager" element_type="attribute" element_name="maxNameLength" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::moveDirectory() method works properly" type="compliance" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P1" id="FileSystemManager_moveDirectory">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_moveDirectory.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileSystemManager" element_type="method" element_name="moveDirectory" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::moveDirectory() method with invalid path throws InvalidValuesError" type="compliance" onload_delay="90" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileSystemManager_moveDirectory_InvalidValuesError">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_moveDirectory_InvalidValuesError.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileSystemManager" element_type="method" element_name="moveDirectory" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::moveDirectory() method throws exception when errorCallback is invalid" type="compliance" onload_delay="90" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileSystemManager_moveDirectory_errorCallback_invalid_cb">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_moveDirectory_errorCallback_invalid_cb.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileSystemManager" element_type="method" element_name="moveDirectory" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::moveDirectory() method throws NotFoundError when path not exists" type="compliance" onload_delay="90" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileSystemManager_moveDirectory_errorCallback_invoked_NotFoundError">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_moveDirectory_errorCallback_invoked_NotFoundError.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileSystemManager" element_type="method" element_name="moveDirectory" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::moveDirectory() method exists" type="compliance" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P0" id="FileSystemManager_moveDirectory_exist">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_moveDirectory_exist.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileSystemManager" element_type="method" element_name="moveDirectory" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::moveDirectory() method with missing mandatory argument throws exception" type="compliance" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileSystemManager_moveDirectory_misarg">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_moveDirectory_misarg.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileSystemManager" element_type="method" element_name="moveDirectory" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::moveDirectory() method throws exception for wrong type of onerror" type="compliance" onload_delay="90" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileSystemManager_moveDirectory_onerror_TypeMismatch">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_moveDirectory_onerror_TypeMismatch.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileSystemManager" element_type="method" element_name="moveDirectory" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::moveDirectory() method throws exception for wrong type of onsuccess" type="compliance" onload_delay="90" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileSystemManager_moveDirectory_onsuccess_TypeMismatch">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_moveDirectory_onsuccess_TypeMismatch.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileSystemManager" element_type="method" element_name="moveDirectory" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::moveDirectory() method throws exception when successCallback is invalid" type="compliance" onload_delay="90" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileSystemManager_moveDirectory_successCallback_invalid_cb">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_moveDirectory_successCallback_invalid_cb.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileSystemManager" element_type="method" element_name="moveDirectory" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::moveDirectory() method works properly with errorCallback" type="compliance" onload_delay="90" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P1" id="FileSystemManager_moveDirectory_with_errorCallback">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_moveDirectory_with_errorCallback.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileSystemManager" element_type="method" element_name="moveDirectory" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::moveFile() method works properly" type="compliance" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P1" id="FileSystemManager_moveFile">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_moveFile.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileSystemManager" element_type="method" element_name="moveFile" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::moveFile() method with invalid path throws InvalidValuesError" type="compliance" onload_delay="90" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileSystemManager_moveFile_InvalidValuesError">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_moveFile_InvalidValuesError.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileSystemManager" element_type="method" element_name="moveFile" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::moveFile() method throws exception when errorCallback is invalid" type="compliance" onload_delay="90" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileSystemManager_moveFile_errorCallback_invalid_cb">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_moveFile_errorCallback_invalid_cb.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileSystemManager" element_type="method" element_name="moveFile" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::moveFile() method throws NotFoundError when path not exists" type="compliance" onload_delay="90" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileSystemManager_moveFile_errorCallback_invoked_NotFoundError">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_moveFile_errorCallback_invoked_NotFoundError.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileSystemManager" element_type="method" element_name="moveFile" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::moveFile() method exists" type="compliance" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P0" id="FileSystemManager_moveFile_exist">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_moveFile_exist.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileSystemManager" element_type="method" element_name="moveFile" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::moveFile() method with missing mandatory argument throws exception" type="compliance" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileSystemManager_moveFile_misarg">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_moveFile_misarg.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileSystemManager" element_type="method" element_name="moveFile" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::moveFile() method throws exception for wrong type of onerror" type="compliance" onload_delay="90" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileSystemManager_moveFile_onerror_TypeMismatch">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_moveFile_onerror_TypeMismatch.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileSystemManager" element_type="method" element_name="moveFile" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::moveFile() method throws exception for wrong type of onsuccess" type="compliance" onload_delay="90" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileSystemManager_moveFile_onsuccess_TypeMismatch">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_moveFile_onsuccess_TypeMismatch.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileSystemManager" element_type="method" element_name="moveFile" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::moveFile() method throws exception when successCallback is invalid" type="compliance" onload_delay="90" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileSystemManager_moveFile_successCallback_invalid_cb">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_moveFile_successCallback_invalid_cb.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileSystemManager" element_type="method" element_name="moveFile" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::moveFile() method works properly with errorCallback" type="compliance" onload_delay="90" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P1" id="FileSystemManager_moveFile_with_errorCallback">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_moveFile_with_errorCallback.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileSystemManager" element_type="method" element_name="moveFile" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::openFile() method works properly" type="compliance" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P1" id="FileSystemManager_openFile">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_openFile.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileSystemManager" element_type="method" element_name="openFile" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::openFile() method throws IOError when IO error occurs" type="compliance" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileSystemManager_openFile_IOError">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_openFile_IOError.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileSystemManager" element_type="method" element_name="openFile" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::openFile() method throws NotFoundError when file not exists" type="compliance" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileSystemManager_openFile_NotFoundError">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_openFile_NotFoundError.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileSystemManager" element_type="method" element_name="openFile" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::openFile() method exists" type="compliance" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P0" id="FileSystemManager_openFile_exist">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_openFile_exist.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileSystemManager" element_type="method" element_name="openFile" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::openFile() method with missing mandatory argument throws exception" type="compliance" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileSystemManager_openFile_misarg">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_openFile_misarg.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileSystemManager" element_type="method" element_name="openFile" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::openFile() method works properly with makeParents" type="compliance" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P1" id="FileSystemManager_openFile_with_makeParents">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_openFile_with_makeParents.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileSystemManager" element_type="method" element_name="openFile" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::pathExists() method works properly" type="compliance" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P1" id="FileSystemManager_pathExists">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_pathExists.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileSystemManager" element_type="method" element_name="pathExists" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::pathExists() method with invalid path throws InvalidValuesError" type="compliance" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileSystemManager_pathExists_InvalidValuesError">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_pathExists_InvalidValuesError.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileSystemManager" element_type="method" element_name="pathExists" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::pathExists() method exists" type="compliance" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P0" id="FileSystemManager_pathExists_exist">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_pathExists_exist.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileSystemManager" element_type="method" element_name="pathExists" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::rename() method works properly" type="compliance" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P1" id="FileSystemManager_rename">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_rename.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileSystemManager" element_type="method" element_name="rename" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::rename() method with invalid name throws InvalidValuesError" type="compliance" onload_delay="90" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileSystemManager_rename_InvalidValuesError">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_rename_InvalidValuesError.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileSystemManager" element_type="method" element_name="rename" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::rename() method throws exception when errorCallback is invalid" type="compliance" onload_delay="90" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileSystemManager_rename_errorCallback_invalid_cb">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_rename_errorCallback_invalid_cb.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileSystemManager" element_type="method" element_name="rename" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::rename() method throws IOError if conflicting file name exists" type="compliance" onload_delay="90" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileSystemManager_rename_errorCallback_invoked_IOError">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_rename_errorCallback_invoked_IOError.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileSystemManager" element_type="method" element_name="rename" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::rename() method throws NotFoundError if path points to non-existing file" type="compliance" onload_delay="90" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileSystemManager_rename_errorCallback_invoked_NotFoundError">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_rename_errorCallback_invoked_NotFoundError.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileSystemManager" element_type="method" element_name="rename" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::rename() method exists" type="compliance" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P0" id="FileSystemManager_rename_exist">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_rename_exist.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileSystemManager" element_type="method" element_name="rename" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::rename() method with missing mandatory argument throws exception" type="compliance" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileSystemManager_rename_misarg">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_rename_misarg.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileSystemManager" element_type="method" element_name="rename" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::rename() method throws exception for wrong type of onerror" type="compliance" onload_delay="90" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileSystemManager_rename_onerror_TypeMismatch">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_rename_onerror_TypeMismatch.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileSystemManager" element_type="method" element_name="rename" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::rename() method throws exception for wrong type of onsuccess" type="compliance" onload_delay="90" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileSystemManager_rename_onsuccess_TypeMismatch">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_rename_onsuccess_TypeMismatch.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileSystemManager" element_type="method" element_name="rename" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::rename() method throws exception when successCallback is invalid" type="compliance" onload_delay="90" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileSystemManager_rename_successCallback_invalid_cb">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_rename_successCallback_invalid_cb.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileSystemManager" element_type="method" element_name="rename" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::rename() method works properly with errorCallback" type="compliance" onload_delay="90" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P1" id="FileSystemManager_rename_with_errorCallback">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_rename_with_errorCallback.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileSystemManager" element_type="method" element_name="rename" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::toURI() method works properly" type="compliance" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P1" id="FileSystemManager_toURI">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_toURI.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileSystemManager" element_type="method" element_name="toURI" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::toURI() method with invalid path throws InvalidValuesError" type="compliance" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileSystemManager_toURI_InvalidValuesError">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_toURI_InvalidValuesError.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileSystemManager" element_type="method" element_name="toURI" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::toURI() method exists" type="compliance" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P0" id="FileSystemManager_toURI_exist">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_toURI_exist.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="FileSystemManager" element_type="method" element_name="toURI" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if interface ListDirectorySuccessCallback exists, it should not" type="compliance" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P3" id="ListDirectorySuccessCallback_notexist">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/ListDirectorySuccessCallback_notexist.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="ListDirectorySuccessCallback" usage="true" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if ListDirectorySuccessCallback::onsuccess() works properly" type="compliance" onload_delay="90" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P1" id="ListDirectorySuccessCallback_onsuccess">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/ListDirectorySuccessCallback_onsuccess.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="ListDirectorySuccessCallback" element_type="method" element_name="onsuccess" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if interface ReadBlobSuccessCallback exists, it should not" type="compliance" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P3" id="ReadBlobSuccessCallback_notexist">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/ReadBlobSuccessCallback_notexist.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="ReadBlobSuccessCallback" usage="true" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if ReadBlobSuccessCallback::onsuccess() works properly" type="compliance" onload_delay="90" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P1" id="ReadBlobSuccessCallback_onsuccess">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/ReadBlobSuccessCallback_onsuccess.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="ReadBlobSuccessCallback" element_type="method" element_name="onsuccess" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if interface ReadDataSuccessCallback exists, it should not" type="compliance" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P3" id="ReadDataSuccessCallback_notexist">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/ReadDataSuccessCallback_notexist.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="ReadDataSuccessCallback" usage="true" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if ReadDataSuccessCallback::onsuccess() works properly" type="compliance" onload_delay="90" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P1" id="ReadDataSuccessCallback_onsuccess">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/ReadDataSuccessCallback_onsuccess.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="ReadDataSuccessCallback" element_type="method" element_name="onsuccess" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if interface ReadStringSuccessCallback exists, it should not" type="compliance" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P3" id="ReadStringSuccessCallback_notexist">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/ReadStringSuccessCallback_notexist.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="ReadStringSuccessCallback" usage="true" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if ReadStringSuccessCallback::onsuccess() works properly" type="compliance" onload_delay="90" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P1" id="ReadStringSuccessCallback_onsuccess">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/ReadStringSuccessCallback_onsuccess.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="ReadStringSuccessCallback" element_type="method" element_name="onsuccess" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if interface SeekSuccessCallback exists, it should not" type="compliance" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P3" id="SeekSuccessCallback_notexist">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/SeekSuccessCallback_notexist.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="SeekSuccessCallback" usage="true" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if SeekSuccessCallback::onsuccess() works properly" type="compliance" onload_delay="90" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P1" id="SeekSuccessCallback_onsuccess">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/SeekSuccessCallback_onsuccess.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="SeekSuccessCallback" element_type="method" element_name="onsuccess" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if interface WriteStringSuccessCallback exists, it should not" type="compliance" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P3" id="WriteStringSuccessCallback_notexist">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/WriteStringSuccessCallback_notexist.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="WriteStringSuccessCallback" usage="true" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if WriteStringSuccessCallback::onsuccess() works properly" type="compliance" onload_delay="90" status="approved" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P1" id="WriteStringSuccessCallback_onsuccess">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/WriteStringSuccessCallback_onsuccess.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion interface="WriteStringSuccessCallback" element_type="method" element_name="onsuccess" specification="Filesystem" section="IO" category="Tizen Device API Specifications"/>
+ <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/filesystem.html</spec_url>
+ <spec_statement>TBD</spec_statement>
+ </spec>
+ </specs>
+ </testcase>
</set>
</suite>
</test_definition>
<test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileStream_writeBase64_invalid.html</test_script_entry>
</description>
</testcase> -->
- <testcase purpose="Check if File::createFile() with missing mandatory argument throws exception" component="TizenAPI/IO/Filesystem" execution_type="auto" id="File_createFile_misarg" priority="P2">
+ <testcase purpose="Check if File::createFile() with missing mandatory argument throws exception" component="TizenAPI/IO/Filesystem" execution_type="auto" id="File_createFile_misarg" priority="P2">
<description>
<test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/File_createFile_misarg.html</test_script_entry>
</description>
- </testcase>
+ </testcase>
+ <testcase purpose="Check if FileHandle::close() method works properly" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P1" id="FileHandle_close">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_close.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileHandle::closeNonBlocking() method works properly" onload_delay="90" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P1" id="FileHandle_closeNonBlocking">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_closeNonBlocking.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileHandle::closeNonBlocking() method throws exception when errorCallback is invalid" onload_delay="90" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileHandle_closeNonBlocking_errorCallback_invalid_cb">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_closeNonBlocking_errorCallback_invalid_cb.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileHandle::closeNonBlocking() method exists" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P0" id="FileHandle_closeNonBlocking_exist">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_closeNonBlocking_exist.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileHandle::closeNonBlocking() method throws exception for wrong type of onerror" onload_delay="90" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileHandle_closeNonBlocking_onerror_TypeMismatch">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_closeNonBlocking_onerror_TypeMismatch.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileHandle::closeNonBlocking() method throws exception for wrong type of onsuccess" onload_delay="90" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileHandle_closeNonBlocking_onsuccess_TypeMismatch">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_closeNonBlocking_onsuccess_TypeMismatch.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileHandle::closeNonBlocking() method throws exception when successCallback is invalid" onload_delay="90" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileHandle_closeNonBlocking_successCallback_invalid_cb">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_closeNonBlocking_successCallback_invalid_cb.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileHandle::closeNonBlocking() method works properly with onerror" onload_delay="90" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P1" id="FileHandle_closeNonBlocking_with_onerror">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_closeNonBlocking_with_onerror.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileHandle::close() method exists" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P0" id="FileHandle_close_exist">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_close_exist.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check using FileHandle::close() method with extra argument" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P1" id="FileHandle_close_extra_argument">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_close_extra_argument.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileHandle::flush() method works properly" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P1" id="FileHandle_flush">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_flush.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileHandle::flushNonBlocking() method works properly" onload_delay="90" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P1" id="FileHandle_flushNonBlocking">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_flushNonBlocking.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileHandle::flushNonBlocking() method throws exception when errorCallback is invalid" onload_delay="90" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileHandle_flushNonBlocking_errorCallback_invalid_cb">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_flushNonBlocking_errorCallback_invalid_cb.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if errorcallback of FileHandle::flushNonBlocking() method can be invoked if input/output error occurs" onload_delay="90" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileHandle_flushNonBlocking_errorCallback_invoked_IOError">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_flushNonBlocking_errorCallback_invoked_IOError.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileHandle::flushNonBlocking() method exists" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P0" id="FileHandle_flushNonBlocking_exist">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_flushNonBlocking_exist.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileHandle::flushNonBlocking() method throws exception for wrong type of onerror" onload_delay="90" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileHandle_flushNonBlocking_onerror_TypeMismatch">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_flushNonBlocking_onerror_TypeMismatch.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileHandle::flushNonBlocking() method throws exception for wrong type of onsuccess" onload_delay="90" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileHandle_flushNonBlocking_onsuccess_TypeMismatch">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_flushNonBlocking_onsuccess_TypeMismatch.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileHandle::flushNonBlocking() method throws exception when successCallback is invalid" onload_delay="90" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileHandle_flushNonBlocking_successCallback_invalid_cb">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_flushNonBlocking_successCallback_invalid_cb.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileHandle::flushNonBlocking() method works properly with onerror" onload_delay="90" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P1" id="FileHandle_flushNonBlocking_with_onerror">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_flushNonBlocking_with_onerror.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileHandle::flush() method exists" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P0" id="FileHandle_flush_exist">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_flush_exist.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check using FileHandle::flush() method with extra argument" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P1" id="FileHandle_flush_extra_argument">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_flush_extra_argument.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Interface FileHandle should not be accessible" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P3" id="FileHandle_notexist">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_notexist.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileHandle::path attribute exists, has type DOMString and is readonly" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P1" id="FileHandle_path_attribute">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_path_attribute.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileHandle::readBlob() method works properly" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P1" id="FileHandle_readBlob">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_readBlob.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileHandle::readBlobNonBlocking() method works properly" onload_delay="90" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P1" id="FileHandle_readBlobNonBlocking">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_readBlobNonBlocking.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileHandle::readBlobNonBlocking() method with invalid count throws InvalidValuesError" onload_delay="90" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileHandle_readBlobNonBlocking_InvalidValuesError">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_readBlobNonBlocking_InvalidValuesError.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileHandle::readBlobNonBlocking() method throws exception when errorCallback is invalid" onload_delay="90" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileHandle_readBlobNonBlocking_errorCallback_invalid_cb">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_readBlobNonBlocking_errorCallback_invalid_cb.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if errorcallback of FileHandle::readBlobNonBlocking() method can be invoked if input/output error occurs" onload_delay="90" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileHandle_readBlobNonBlocking_errorCallback_invoked_IOError">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_readBlobNonBlocking_errorCallback_invoked_IOError.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileHandle::readBlobNonBlocking() method exists" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P0" id="FileHandle_readBlobNonBlocking_exist">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_readBlobNonBlocking_exist.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileHandle::readBlobNonBlocking() method throws exception for wrong type of onerror" onload_delay="90" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileHandle_readBlobNonBlocking_onerror_TypeMismatch">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_readBlobNonBlocking_onerror_TypeMismatch.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileHandle::readBlobNonBlocking() method throws exception for wrong type of onsuccess" onload_delay="90" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileHandle_readBlobNonBlocking_onsuccess_TypeMismatch">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_readBlobNonBlocking_onsuccess_TypeMismatch.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileHandle::readBlobNonBlocking() method throws exception when successCallback is invalid" onload_delay="90" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileHandle_readBlobNonBlocking_successCallback_invalid_cb">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_readBlobNonBlocking_successCallback_invalid_cb.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileHandle::readBlobNonBlocking() method works properly with inputEncoding" onload_delay="90" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P1" id="FileHandle_readBlobNonBlocking_with_size">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_readBlobNonBlocking_with_size.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileHandle::readBlob() method with file handle closed throws IOError" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileHandle_readBlob_IOError">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_readBlob_IOError.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileHandle::readBlob() method with invalid count throws InvalidValuesError" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileHandle_readBlob_InvalidValuesError">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_readBlob_InvalidValuesError.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileHandle::readBlob() method exists" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P0" id="FileHandle_readBlob_exist">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_readBlob_exist.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileHandle::readBlob() method works properly with size" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P1" id="FileHandle_readBlob_with_size">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_readBlob_with_size.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileHandle::readData() method works properly" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P1" id="FileHandle_readData">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_readData.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileHandle::readDataNonBlocking() method works properly" onload_delay="90" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P1" id="FileHandle_readDataNonBlocking">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_readDataNonBlocking.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileHandle::readDataNonBlocking() method with invalid size throws InvalidValuesError" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileHandle_readDataNonBlocking_InvalidValuesError">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_readDataNonBlocking_InvalidValuesError.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileHandle::readDataNonBlocking() method throws exception when errorCallback is invalid" onload_delay="90" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileHandle_readDataNonBlocking_errorCallback_invalid_cb">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_readDataNonBlocking_errorCallback_invalid_cb.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if errorcallback of FileHandle::readDataNonBlocking() method can be invoked with file handle occurs error" onload_delay="90" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileHandle_readDataNonBlocking_errorCallback_invoked">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_readDataNonBlocking_errorCallback_invoked.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileHandle::readDataNonBlocking() method exists" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P0" id="FileHandle_readDataNonBlocking_exist">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_readDataNonBlocking_exist.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileHandle::readDataNonBlocking() method throws exception for wrong type of onerror" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileHandle_readDataNonBlocking_onerror_TypeMismatch">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_readDataNonBlocking_onerror_TypeMismatch.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileHandle::readDataNonBlocking() method throws exception for wrong type of onsuccess" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileHandle_readDataNonBlocking_onsuccess_TypeMismatch">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_readDataNonBlocking_onsuccess_TypeMismatch.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileHandle::readDataNonBlocking() method throws exception when successCallback is invalid" onload_delay="90" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileHandle_readDataNonBlocking_successCallback_invalid_cb">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_readDataNonBlocking_successCallback_invalid_cb.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileHandle::readDataNonBlocking() method works properly with size" onload_delay="90" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P1" id="FileHandle_readDataNonBlocking_with_size">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_readDataNonBlocking_with_size.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileHandle::readData() method with file handle closed throws IOError" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileHandle_readData_IOError">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_readData_IOError.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileHandle::readData() method with invalid size throws InvalidValuesError" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileHandle_readData_InvalidValuesError">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_readData_InvalidValuesError.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileHandle::readData() method exists" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P0" id="FileHandle_readData_exist">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_readData_exist.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileHandle::readData() method works properly with size" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P1" id="FileHandle_readData_with_size">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_readData_with_size.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileHandle::readString() method works properly" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P1" id="FileHandle_readString">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_readString.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileHandle::readStringNonBlocking() method works properly" onload_delay="90" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P1" id="FileHandle_readStringNonBlocking">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_readStringNonBlocking.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileHandle::readStringNonBlocking() method throws exception when errorCallback is invalid" onload_delay="90" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileHandle_readStringNonBlocking_errorCallback_invalid_cb">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_readStringNonBlocking_errorCallback_invalid_cb.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if errorcallback of FileHandle::readStringNonBlocking() method can be invoked if input/output error occurs" onload_delay="90" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileHandle_readStringNonBlocking_errorCallback_invoked_IOError">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_readStringNonBlocking_errorCallback_invoked_IOError.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileHandle::readStringNonBlocking() method exists" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P0" id="FileHandle_readStringNonBlocking_exist">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_readStringNonBlocking_exist.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileHandle::readStringNonBlocking() method with invalid count throws InvalidValuesError" onload_delay="90" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileHandle_readStringNonBlocking_InvalidValuesError">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_readStringNonBlocking_InvalidValuesError.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if readStringNonBlocking() method with not-supported encoding throws NotSupportedError" onload_delay="90" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileHandle_readStringNonBlocking_NotSupportedError">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_readStringNonBlocking_NotSupportedError.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileHandle::readStringNonBlocking() method throws exception for wrong type of onerror" onload_delay="90" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileHandle_readStringNonBlocking_onerror_TypeMismatch">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_readStringNonBlocking_onerror_TypeMismatch.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileHandle::readStringNonBlocking() method throws exception for wrong type of onsuccess" onload_delay="90" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileHandle_readStringNonBlocking_onsuccess_TypeMismatch">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_readStringNonBlocking_onsuccess_TypeMismatch.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileHandle::readStringNonBlocking() method throws exception when successCallback is invalid" onload_delay="90" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileHandle_readStringNonBlocking_successCallback_invalid_cb">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_readStringNonBlocking_successCallback_invalid_cb.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileHandle::readStringNonBlocking() method works properly with inputEncoding" onload_delay="90" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P1" id="FileHandle_readStringNonBlocking_with_inputEncoding">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_readStringNonBlocking_with_inputEncoding.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileHandle::readString() method with file handle closed throws IOError" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileHandle_readString_IOError">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_readString_IOError.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileHandle::readString() method with invalid count throws InvalidValuesError" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileHandle_readString_InvalidValuesError">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_readString_InvalidValuesError.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileHandle::readString() method with invalid encoding throws NotSupportedError" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileHandle_readString_NotSupportedError">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_readString_NotSupportedError.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileHandle::readString() method exists" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P0" id="FileHandle_readString_exist">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_readString_exist.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileHandle::readString() method works properly with inputEncoding" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P1" id="FileHandle_readString_with_inputEncoding">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_readString_with_inputEncoding.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileHandle::seek() method works properly" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P1" id="FileHandle_seek">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_seek.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileHandle::seekNonBlocking() method works properly" onload_delay="90" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P1" id="FileHandle_seekNonBlocking">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_seekNonBlocking.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileHandle::seekNonBlocking() method throws exception when errorCallback is invalid" onload_delay="90" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileHandle_seekNonBlocking_errorCallback_invalid_cb">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_seekNonBlocking_errorCallback_invalid_cb.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if errorcallback of FileHandle::seekNonBlocking() method can be invoked with file handle occurs error" onload_delay="90" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileHandle_seekNonBlocking_errorCallback_invoked">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_seekNonBlocking_errorCallback_invoked.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileHandle::seekNonBlocking() method exists" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P0" id="FileHandle_seekNonBlocking_exist">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_seekNonBlocking_exist.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileHandle::seekNonBlocking() method throws exception for wrong type of onerror" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileHandle_seekNonBlocking_onerror_TypeMismatch">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_seekNonBlocking_onerror_TypeMismatch.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileHandle::seekNonBlocking() method throws exception for wrong type of onsuccess" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileHandle_seekNonBlocking_onsuccess_TypeMismatch">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_seekNonBlocking_onsuccess_TypeMismatch.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileHandle::seekNonBlocking() method throws exception when successCallback is invalid" onload_delay="90" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileHandle_seekNonBlocking_successCallback_invalid_cb">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_seekNonBlocking_successCallback_invalid_cb.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileHandle::seekNonBlocking() method works properly with BaseSeekPosition whence" onload_delay="90" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P1" id="FileHandle_seekNonBlocking_with_whence">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_seekNonBlocking_with_whence.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileHandle::seek() method with file handle closed throws IOError" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileHandle_seek_IOError">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_seek_IOError.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileHandle::seek() method exists" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P0" id="FileHandle_seek_exist">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_seek_exist.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileHandle::seek() method works properly with BaseSeekPosition whence" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P1" id="FileHandle_seek_with_whence">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_seek_with_whence.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileHandle::sync() method works properly" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P1" id="FileHandle_sync">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_sync.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileHandle::syncNonBlocking() method works properly" onload_delay="90" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P1" id="FileHandle_syncNonBlocking">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_syncNonBlocking.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileHandle::syncNonBlocking() method throws exception when errorCallback is invalid" onload_delay="90" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileHandle_syncNonBlocking_errorCallback_invalid_cb">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_syncNonBlocking_errorCallback_invalid_cb.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if errorcallback of FileHandle::syncNonBlocking() method can be invoked with file handle occurs error" onload_delay="90" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileHandle_syncNonBlocking_errorCallback_invoked">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_syncNonBlocking_errorCallback_invoked.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileHandle::syncNonBlocking() method exists" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P0" id="FileHandle_syncNonBlocking_exist">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_syncNonBlocking_exist.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileHandle::syncNonBlocking() method throws exception for wrong type of onerror" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileHandle_syncNonBlocking_onerror_TypeMismatch">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_syncNonBlocking_onerror_TypeMismatch.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileHandle::syncNonBlocking() method throws exception for wrong type of onsuccess" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileHandle_syncNonBlocking_onsuccess_TypeMismatch">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_syncNonBlocking_onsuccess_TypeMismatch.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileHandle::syncNonBlocking() method throws exception when successCallback is invalid" onload_delay="90" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileHandle_syncNonBlocking_successCallback_invalid_cb">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_syncNonBlocking_successCallback_invalid_cb.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileHandle::syncNonBlocking() method works properly with onerror" onload_delay="90" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P1" id="FileHandle_syncNonBlocking_with_onerror">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_syncNonBlocking_with_onerror.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileHandle::sync() method exists" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P0" id="FileHandle_sync_exist">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_sync_exist.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check using FileHandle::sync() method with extra argument" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P1" id="FileHandle_sync_extra_argument">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_sync_extra_argument.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileHandle::writeBlob() method works properly" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P1" id="FileHandle_writeBlob">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_writeBlob.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileHandle::writeBlobNonBlocking() method works properly" onload_delay="90" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P1" id="FileHandle_writeBlobNonBlocking">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_writeBlobNonBlocking.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileHandle:writeBlobNonBlocking() throws exception when blob is incorrect" onload_delay="90" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileHandle_writeBlobNonBlocking_blob_TypeMismatch">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_writeBlobNonBlocking_blob_TypeMismatch.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileHandle::writeBlobNonBlocking() method throws exception when errorCallback is invalid" onload_delay="90" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileHandle_writeBlobNonBlocking_errorCallback_invalid_cb">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_writeBlobNonBlocking_errorCallback_invalid_cb.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if errorcallback of FileHandle::writeBlobNonBlocking() method can be invoked if input/output error occurs" onload_delay="90" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileHandle_writeBlobNonBlocking_errorCallback_invoked_IOError">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_writeBlobNonBlocking_errorCallback_invoked_IOError.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileHandle::writeBlobNonBlocking() method exists" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P0" id="FileHandle_writeBlobNonBlocking_exist">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_writeBlobNonBlocking_exist.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileHandle::writeBlobNonBlocking() method with missing mandatory argument throws exception" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileHandle_writeBlobNonBlocking_misarg">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_writeBlobNonBlocking_misarg.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileHandle::writeBlobNonBlocking() method throws exception for wrong type of onerror" onload_delay="90" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileHandle_writeBlobNonBlocking_onerror_TypeMismatch">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_writeBlobNonBlocking_onerror_TypeMismatch.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileHandle::writeBlobNonBlocking() method throws exception for wrong type of onsuccess" onload_delay="90" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileHandle_writeBlobNonBlocking_onsuccess_TypeMismatch">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_writeBlobNonBlocking_onsuccess_TypeMismatch.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileHandle::writeBlobNonBlocking() method throws exception when successCallback is invalid" onload_delay="90" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileHandle_writeBlobNonBlocking_successCallback_invalid_cb">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_writeBlobNonBlocking_successCallback_invalid_cb.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileHandle::writeBlobNonBlocking() method works properly with onerror" onload_delay="90" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P1" id="FileHandle_writeBlobNonBlocking_with_onerror">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_writeBlobNonBlocking_with_onerror.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileHandle::writeBlob() method with file handle closed throws IOError" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileHandle_writeBlob_IOError">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_writeBlob_IOError.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileHandle:writeBlob() throws exception when blob is incorrect" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileHandle_writeBlob_blob_TypeMismatch">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_writeBlob_blob_TypeMismatch.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileHandle::writeBlob() method exists" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P0" id="FileHandle_writeBlob_exist">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_writeBlob_exist.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileHandle::writeBlob() method with missing mandatory argument throws exception" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileHandle_writeBlob_misarg">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_writeBlob_misarg.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileHandle::writeData() method works properly" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P1" id="FileHandle_writeData">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_writeData.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileHandle::writeDataNonBlocking() method works properly" onload_delay="90" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P1" id="FileHandle_writeDataNonBlocking">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_writeDataNonBlocking.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileHandle::writeDataNonBlocking() method throws exception when errorCallback is invalid" onload_delay="90" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileHandle_writeDataNonBlocking_errorCallback_invalid_cb">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_writeDataNonBlocking_errorCallback_invalid_cb.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if errorcallback of FileHandle::writeDataNonBlocking() method can be invoked with file handle occurs error" onload_delay="90" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileHandle_writeDataNonBlocking_errorCallback_invoked">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_writeDataNonBlocking_errorCallback_invoked.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileHandle::writeDataNonBlocking() method exists" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P0" id="FileHandle_writeDataNonBlocking_exist">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_writeDataNonBlocking_exist.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileHandle::writeDataNonBlocking() method with missing mandatory argument throws exception" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileHandle_writeDataNonBlocking_misarg">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_writeDataNonBlocking_misarg.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileHandle::writeDataNonBlocking() method throws exception for wrong type of onerror" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileHandle_writeDataNonBlocking_onerror_TypeMismatch">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_writeDataNonBlocking_onerror_TypeMismatch.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileHandle::writeDataNonBlocking() method throws exception for wrong type of onsuccess" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileHandle_writeDataNonBlocking_onsuccess_TypeMismatch">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_writeDataNonBlocking_onsuccess_TypeMismatch.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileHandle::writeDataNonBlocking() method throws exception when successCallback is invalid" onload_delay="90" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileHandle_writeDataNonBlocking_successCallback_invalid_cb">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_writeDataNonBlocking_successCallback_invalid_cb.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileHandle::writeDataNonBlocking() method works properly with onerror" onload_delay="90" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P1" id="FileHandle_writeDataNonBlocking_with_onerror">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_writeDataNonBlocking_with_onerror.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileHandle::writeData() method with file handle closed throws IOError" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileHandle_writeData_IOError">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_writeData_IOError.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileHandle:writeData() throws exception when data type is incorrect" onload_delay="90" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileHandle_writeData_data_TypeMismatch">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_writeData_data_TypeMismatch.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileHandle::writeData() method exists" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P0" id="FileHandle_writeData_exist">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_writeData_exist.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileHandle::writeData() method with missing mandatory argument throws exception" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileHandle_writeData_misarg">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_writeData_misarg.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileHandle::writeString() method works properly" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P1" id="FileHandle_writeString">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_writeString.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileHandle::writeStringNonBlocking() method works properly" onload_delay="90" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P1" id="FileHandle_writeStringNonBlocking">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_writeStringNonBlocking.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileHandle::writeStringNonBlocking() method throws exception when errorCallback is invalid" onload_delay="90" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileHandle_writeStringNonBlocking_errorCallback_invalid_cb">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_writeStringNonBlocking_errorCallback_invalid_cb.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if errorcallback of FileHandle::writeStringNonBlocking() method can be invoked if input/output error occurs" onload_delay="90" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileHandle_writeStringNonBlocking_errorCallback_invoked_IOError">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_writeStringNonBlocking_errorCallback_invoked_IOError.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileHandle::writeStringNonBlocking() method exists" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P0" id="FileHandle_writeStringNonBlocking_exist">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_writeStringNonBlocking_exist.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if writeStringNonBlocking() method with not-supported encoding throws NotSupportedError" onload_delay="90" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileHandle_writeStringNonBlocking_NotSupportedError">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_writeStringNonBlocking_NotSupportedError.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileHandle::writeStringNonBlocking() method throws exception for wrong type of onerror" onload_delay="90" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileHandle_writeStringNonBlocking_onerror_TypeMismatch">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_writeStringNonBlocking_onerror_TypeMismatch.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileHandle::writeStringNonBlocking() method throws exception for wrong type of onsuccess" onload_delay="90" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileHandle_writeStringNonBlocking_onsuccess_TypeMismatch">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_writeStringNonBlocking_onsuccess_TypeMismatch.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileHandle::writeStringNonBlocking() method throws exception when successCallback is invalid" onload_delay="90" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileHandle_writeStringNonBlocking_successCallback_invalid_cb">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_writeStringNonBlocking_successCallback_invalid_cb.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileHandle::writeStringNonBlocking() method works properly with outputEncoding" onload_delay="90" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P1" id="FileHandle_writeStringNonBlocking_with_outputEncoding">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_writeStringNonBlocking_with_outputEncoding.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileHandle::writeString() method with file handle closed throws IOError" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileHandle_writeString_IOError">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_writeString_IOError.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileHandle::writeString() method with invalid encoding throws NotSupportedError" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileHandle_writeString_NotSupportedError">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_writeString_NotSupportedError.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileHandle::writeString() method exists" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P0" id="FileHandle_writeString_exist">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_writeString_exist.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileHandle::writeString() method works properly with outputEncoding" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P1" id="FileHandle_writeString_with_outputEncoding">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileHandle_writeString_with_outputEncoding.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::copyDirectory() method works properly" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P1" id="FileSystemManager_copyDirectory">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_copyDirectory.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::copyDirectory() method with invalid path throws InvalidValuesError" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileSystemManager_copyDirectory_InvalidValuesError">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_copyDirectory_InvalidValuesError.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::copyDirectory() method throws exception when errorCallback is invalid" onload_delay="90" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileSystemManager_copyDirectory_errorCallback_invalid_cb">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_copyDirectory_errorCallback_invalid_cb.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::copyDirectory() method throws NotFoundError when path not exists" onload_delay="90" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileSystemManager_copyDirectory_errorCallback_invoked_NotFoundError">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_copyDirectory_errorCallback_invoked_NotFoundError.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::copyDirectory() method exists" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P0" id="FileSystemManager_copyDirectory_exist">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_copyDirectory_exist.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::copyDirectory() method with missing mandatory argument throws exception" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileSystemManager_copyDirectory_misarg">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_copyDirectory_misarg.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::copyDirectory() method throws exception for wrong type of onerror" onload_delay="90" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileSystemManager_copyDirectory_onerror_TypeMismatch">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_copyDirectory_onerror_TypeMismatch.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::copyDirectory() method throws exception for wrong type of onsuccess" onload_delay="90" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileSystemManager_copyDirectory_onsuccess_TypeMismatch">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_copyDirectory_onsuccess_TypeMismatch.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::copyDirectory() method throws exception when successCallback is invalid" onload_delay="90" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileSystemManager_copyDirectory_successCallback_invalid_cb">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_copyDirectory_successCallback_invalid_cb.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::copyDirectory() method works properly with errorCallback" onload_delay="90" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P1" id="FileSystemManager_copyDirectory_with_errorCallback">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_copyDirectory_with_errorCallback.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::copyFile() method works properly" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P1" id="FileSystemManager_copyFile">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_copyFile.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::copyFile() method with invalid path throws InvalidValuesError" onload_delay="90" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileSystemManager_copyFile_InvalidValuesError">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_copyFile_InvalidValuesError.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::copyFile() method throws exception when errorCallback is invalid" onload_delay="90" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileSystemManager_copyFile_errorCallback_invalid_cb">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_copyFile_errorCallback_invalid_cb.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::copyFile() method throws NotFoundError when path not exists" onload_delay="90" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileSystemManager_copyFile_errorCallback_invoked_NotFoundError">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_copyFile_errorCallback_invoked_NotFoundError.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::copyFile() method exists" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P0" id="FileSystemManager_copyFile_exist">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_copyFile_exist.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::copyFile() method with missing mandatory argument throws exception" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileSystemManager_copyFile_misarg">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_copyFile_misarg.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::copyFile() method throws exception for wrong type of onerror" onload_delay="90" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileSystemManager_copyFile_onerror_TypeMismatch">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_copyFile_onerror_TypeMismatch.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::copyFile() method throws exception for wrong type of onsuccess" onload_delay="90" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileSystemManager_copyFile_onsuccess_TypeMismatch">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_copyFile_onsuccess_TypeMismatch.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::copyFile() method throws exception when successCallback is invalid" onload_delay="90" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileSystemManager_copyFile_successCallback_invalid_cb">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_copyFile_successCallback_invalid_cb.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::copyFile() method works properly with errorCallback" onload_delay="90" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P1" id="FileSystemManager_copyFile_with_errorCallback">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_copyFile_with_errorCallback.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::createDirectory() method works properly" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P1" id="FileSystemManager_createDirectory">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_createDirectory.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::createDirectory() method with invalid path throws InvalidValuesError" onload_delay="90" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileSystemManager_createDirectory_InvalidValuesError">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_createDirectory_InvalidValuesError.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::createDirectory() method throws exception when errorCallback is invalid" onload_delay="90" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileSystemManager_createDirectory_errorCallback_invalid_cb">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_createDirectory_errorCallback_invalid_cb.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::createDirectory() method throws NotFoundError when path not exists" onload_delay="90" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileSystemManager_createDirectory_errorCallback_invoked_NotFoundError">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_createDirectory_errorCallback_invoked_NotFoundError.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::createDirectory() method exists" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P0" id="FileSystemManager_createDirectory_exist">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_createDirectory_exist.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::createDirectory() method throws exception for wrong type of onerror" onload_delay="90" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileSystemManager_createDirectory_onerror_TypeMismatch">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_createDirectory_onerror_TypeMismatch.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::createDirectory() method throws exception for wrong type of onsuccess" onload_delay="90" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileSystemManager_createDirectory_onsuccess_TypeMismatch">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_createDirectory_onsuccess_TypeMismatch.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::createDirectory() method throws exception when successCallback is invalid" onload_delay="90" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileSystemManager_createDirectory_successCallback_invalid_cb">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_createDirectory_successCallback_invalid_cb.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::createDirectory() method works properly with errorCallback" onload_delay="90" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P1" id="FileSystemManager_createDirectory_with_errorCallback">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_createDirectory_with_errorCallback.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::deleteDirectory() method works properly" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P1" id="FileSystemManager_deleteDirectory">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_deleteDirectory.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::deleteDirectory() method with invalid path throws InvalidValuesError" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileSystemManager_deleteDirectory_InvalidValuesError">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_deleteDirectory_InvalidValuesError.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::deleteDirectory() method throws exception when errorCallback is invalid" onload_delay="90" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileSystemManager_deleteDirectory_errorCallback_invalid_cb">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_deleteDirectory_errorCallback_invalid_cb.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::deleteDirectory() method throws NotFoundError when path not exists" onload_delay="90" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileSystemManager_deleteDirectory_errorCallback_invoked_NotFoundError">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_deleteDirectory_errorCallback_invoked_NotFoundError.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::deleteDirectory() method exists" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P0" id="FileSystemManager_deleteDirectory_exist">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_deleteDirectory_exist.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::deleteDirectory() method throws exception for wrong type of onerror" onload_delay="90" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileSystemManager_deleteDirectory_onerror_TypeMismatch">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_deleteDirectory_onerror_TypeMismatch.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::deleteDirectory() method throws exception for wrong type of onsuccess" onload_delay="90" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileSystemManager_deleteDirectory_onsuccess_TypeMismatch">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_deleteDirectory_onsuccess_TypeMismatch.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::deleteDirectory() method throws exception when successCallback is invalid" onload_delay="90" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileSystemManager_deleteDirectory_successCallback_invalid_cb">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_deleteDirectory_successCallback_invalid_cb.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::deleteDirectory() method works properly with errorCallback" onload_delay="90" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P1" id="FileSystemManager_deleteDirectory_with_errorCallback">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_deleteDirectory_with_errorCallback.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::deleteFile() method works properly with makeParents" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P1" id="FileSystemManager_deleteFile">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_deleteFile.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::deleteFile() method with invalid path throws InvalidValuesError" onload_delay="90" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileSystemManager_deleteFile_InvalidValuesError">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_deleteFile_InvalidValuesError.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::deleteFile() method throws exception when errorCallback is invalid" onload_delay="90" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileSystemManager_deleteFile_errorCallback_invalid_cb">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_deleteFile_errorCallback_invalid_cb.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::deleteFile() method throws NotFoundError when file not exists" onload_delay="90" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileSystemManager_deleteFile_errorCallback_invoked_NotFoundError">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_deleteFile_errorCallback_invoked_NotFoundError.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::deleteFile() method exists" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P0" id="FileSystemManager_deleteFile_exist">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_deleteFile_exist.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::deleteFile() method throws exception for wrong type of onerror" onload_delay="90" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileSystemManager_deleteFile_onerror_TypeMismatch">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_deleteFile_onerror_TypeMismatch.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::deleteFile() method throws exception for wrong type of onsuccess" onload_delay="90" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileSystemManager_deleteFile_with_errorCallback">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_deleteFile_onsuccess_TypeMismatch.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::deleteFile() method throws exception when successCallback is invalid" onload_delay="90" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileSystemManager_deleteFile_successCallback_invalid_cb">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_deleteFile_successCallback_invalid_cb.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::deleteFile() method works properly with errorCallback" onload_delay="90" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P1" id="FileSystemManager_deleteFile_with_errorCallback">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_deleteFile_with_errorCallback.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::getDirName() method works properly" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P1" id="FileSystemManager_getDirName">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_getDirName.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::getDirName() method exists" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P0" id="FileSystemManager_getDirName_exist">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_getDirName_exist.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::isDirectory() method works properly" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P1" id="FileSystemManager_isDirectory">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_isDirectory.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::isDirectory() method with invalid path throws InvalidValuesError" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileSystemManager_isDirectory_InvalidValuesError">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_isDirectory_InvalidValuesError.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::isDirectory() method throws NotFoundError when path not exists" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileSystemManager_isDirectory_NotFoundError">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_isDirectory_NotFoundError.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::isDirectory() method exists" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P0" id="FileSystemManager_isDirectory_exist">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_isDirectory_exist.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::isDirectory() method with missing mandatory argument throws exception" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileSystemManager_isDirectory_misarg">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_isDirectory_misarg.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::isFile() method works properly" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P1" id="FileSystemManager_isFile">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_isFile.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::isFile() method with invalid path throws InvalidValuesError" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileSystemManager_isFile_InvalidValuesError">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_isFile_InvalidValuesError.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::isFile() method throws NotFoundError when file not exists" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileSystemManager_isFile_NotFoundError">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_isFile_NotFoundError.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::isFile() method exists" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P0" id="FileSystemManager_isFile_exist">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_isFile_exist.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::isFile() method with missing mandatory argument throws exception" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileSystemManager_isFile_misarg">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_isFile_misarg.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::listDirectory() method works properly" onload_delay="90" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P1" id="FileSystemManager_listDirectory">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_listDirectory.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::listDirectory() method throws exception when errorCallback is invalid" onload_delay="90" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileSystemManager_listDirectory_errorCallback_invalid_cb">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_listDirectory_errorCallback_invalid_cb.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::listDirectory() method throws NotFoundError when path not exists" onload_delay="90" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileSystemManager_listDirectory_errorCallback_invoked_NotFoundError">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_listDirectory_errorCallback_invoked_NotFoundError.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::listDirectory() method exists" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P0" id="FileSystemManager_listDirectory_exist">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_listDirectory_exist.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::listDirectory() method with invalid path throws InvalidValuesError" onload_delay="90" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileSystemManager_listDirectory_InvalidValuesError">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_listDirectory_InvalidValuesError.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::listDirectory() method with missing mandatory argument throws exception" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileSystemManager_listDirectory_misarg">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_listDirectory_misarg.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::listDirectory() method throws exception for wrong type of onerror" onload_delay="90" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileSystemManager_listDirectory_onerror_TypeMismatch">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_listDirectory_onerror_TypeMismatch.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::listDirectory() method throws exception for wrong type of onsuccess" onload_delay="90" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileSystemManager_listDirectory_onsuccess_TypeMismatch">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_listDirectory_onsuccess_TypeMismatch.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::listDirectory() method throws exception when successCallback is invalid" onload_delay="90" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileSystemManager_listDirectory_successCallback_invalid_cb">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_listDirectory_successCallback_invalid_cb.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::listDirectory() method works properly with filter" onload_delay="90" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P1" id="FileSystemManager_listDirectory_with_filter">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_listDirectory_with_filter.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if attribute maxNameLength of FileSystemManager exists, has type long and is readonly" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P1" id="FileSystemManager_maxNameLength_attribute">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_maxNameLength_attribute.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::moveDirectory() method works properly" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P1" id="FileSystemManager_moveDirectory">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_moveDirectory.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::moveDirectory() method with invalid path throws InvalidValuesError" onload_delay="90" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileSystemManager_moveDirectory_InvalidValuesError">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_moveDirectory_InvalidValuesError.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::moveDirectory() method throws exception when errorCallback is invalid" onload_delay="90" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileSystemManager_moveDirectory_errorCallback_invalid_cb">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_moveDirectory_errorCallback_invalid_cb.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::moveDirectory() method throws NotFoundError when path not exists" onload_delay="90" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileSystemManager_moveDirectory_errorCallback_invoked_NotFoundError">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_moveDirectory_errorCallback_invoked_NotFoundError.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::moveDirectory() method exists" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P0" id="FileSystemManager_moveDirectory_exist">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_moveDirectory_exist.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::moveDirectory() method with missing mandatory argument throws exception" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileSystemManager_moveDirectory_misarg">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_moveDirectory_misarg.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::moveDirectory() method throws exception for wrong type of onerror" onload_delay="90" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileSystemManager_moveDirectory_onerror_TypeMismatch">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_moveDirectory_onerror_TypeMismatch.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::moveDirectory() method throws exception for wrong type of onsuccess" onload_delay="90" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileSystemManager_moveDirectory_onsuccess_TypeMismatch">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_moveDirectory_onsuccess_TypeMismatch.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::moveDirectory() method throws exception when successCallback is invalid" onload_delay="90" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileSystemManager_moveDirectory_successCallback_invalid_cb">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_moveDirectory_successCallback_invalid_cb.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::moveDirectory() method works properly with errorCallback" onload_delay="90" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P1" id="FileSystemManager_moveDirectory_with_errorCallback">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_moveDirectory_with_errorCallback.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::moveFile() method works properly" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P1" id="FileSystemManager_moveFile">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_moveFile.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::moveFile() method with invalid path throws InvalidValuesError" onload_delay="90" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileSystemManager_moveFile_InvalidValuesError">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_moveFile_InvalidValuesError.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::moveFile() method throws exception when errorCallback is invalid" onload_delay="90" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileSystemManager_moveFile_errorCallback_invalid_cb">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_moveFile_errorCallback_invalid_cb.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::moveFile() method throws NotFoundError when path not exists" onload_delay="90" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileSystemManager_moveFile_errorCallback_invoked_NotFoundError">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_moveFile_errorCallback_invoked_NotFoundError.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::moveFile() method exists" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P0" id="FileSystemManager_moveFile_exist">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_moveFile_exist.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::moveFile() method with missing mandatory argument throws exception" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileSystemManager_moveFile_misarg">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_moveFile_misarg.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::moveFile() method throws exception for wrong type of onerror" onload_delay="90" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileSystemManager_moveFile_onerror_TypeMismatch">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_moveFile_onerror_TypeMismatch.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::moveFile() method throws exception for wrong type of onsuccess" onload_delay="90" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileSystemManager_moveFile_onsuccess_TypeMismatch">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_moveFile_onsuccess_TypeMismatch.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::moveFile() method throws exception when successCallback is invalid" onload_delay="90" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileSystemManager_moveFile_successCallback_invalid_cb">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_moveFile_successCallback_invalid_cb.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::moveFile() method works properly with errorCallback" onload_delay="90" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P1" id="FileSystemManager_moveFile_with_errorCallback">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_moveFile_with_errorCallback.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::openFile() method works properly" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P1" id="FileSystemManager_openFile">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_openFile.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::openFile() method throws IOError when IO error occurs" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileSystemManager_openFile_IOError">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_openFile_IOError.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::openFile() method throws NotFoundError when file not exists" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileSystemManager_openFile_NotFoundError">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_openFile_NotFoundError.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::openFile() method exists" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P0" id="FileSystemManager_openFile_exist">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_openFile_exist.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::openFile() method with missing mandatory argument throws exception" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileSystemManager_openFile_misarg">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_openFile_misarg.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::openFile() method works properly with makeParents" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P1" id="FileSystemManager_openFile_with_makeParents">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_openFile_with_makeParents.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::pathExists() method works properly" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P1" id="FileSystemManager_pathExists">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_pathExists.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::pathExists() method with invalid path throws InvalidValuesError" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileSystemManager_pathExists_InvalidValuesError">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_pathExists_InvalidValuesError.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::pathExists() method exists" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P0" id="FileSystemManager_pathExists_exist">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_pathExists_exist.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::rename() method works properly" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P1" id="FileSystemManager_rename">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_rename.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::rename() method with invalid name throws InvalidValuesError" onload_delay="90" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileSystemManager_rename_InvalidValuesError">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_rename_InvalidValuesError.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::rename() method throws exception when errorCallback is invalid" onload_delay="90" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileSystemManager_rename_errorCallback_invalid_cb">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_rename_errorCallback_invalid_cb.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::rename() method throws IOError if conflicting file name exists" onload_delay="90" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileSystemManager_rename_errorCallback_invoked_IOError">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_rename_errorCallback_invoked_IOError.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::rename() method throws NotFoundError if path points to non-existing file" onload_delay="90" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileSystemManager_rename_errorCallback_invoked_NotFoundError">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_rename_errorCallback_invoked_NotFoundError.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::rename() method exists" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P0" id="FileSystemManager_rename_exist">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_rename_exist.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::rename() method with missing mandatory argument throws exception" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileSystemManager_rename_misarg">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_rename_misarg.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::rename() method throws exception for wrong type of onerror" onload_delay="90" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileSystemManager_rename_onerror_TypeMismatch">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_rename_onerror_TypeMismatch.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::rename() method throws exception for wrong type of onsuccess" onload_delay="90" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileSystemManager_rename_onsuccess_TypeMismatch">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_rename_onsuccess_TypeMismatch.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::rename() method throws exception when successCallback is invalid" onload_delay="90" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileSystemManager_rename_successCallback_invalid_cb">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_rename_successCallback_invalid_cb.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::rename() method works properly with errorCallback" onload_delay="90" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P1" id="FileSystemManager_rename_with_errorCallback">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_rename_with_errorCallback.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::toURI() method works properly" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P1" id="FileSystemManager_toURI">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_toURI.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::toURI() method with invalid path throws InvalidValuesError" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P2" id="FileSystemManager_toURI_InvalidValuesError">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_toURI_InvalidValuesError.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if FileSystemManager::toURI() method exists" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P0" id="FileSystemManager_toURI_exist">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/FileSystemManager_toURI_exist.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if interface ListDirectorySuccessCallback exists, it should not" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P3" id="ListDirectorySuccessCallback_notexist">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/ListDirectorySuccessCallback_notexist.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if ListDirectorySuccessCallback::onsuccess() works properly" onload_delay="90" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P1" id="ListDirectorySuccessCallback_onsuccess">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/ListDirectorySuccessCallback_onsuccess.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if interface ReadBlobSuccessCallback exists, it should not" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P3" id="ReadBlobSuccessCallback_notexist">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/ReadBlobSuccessCallback_notexist.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if ReadBlobSuccessCallback::onsuccess() works properly" onload_delay="90" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P1" id="ReadBlobSuccessCallback_onsuccess">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/ReadBlobSuccessCallback_onsuccess.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if interface ReadDataSuccessCallback exists, it should not" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P3" id="ReadDataSuccessCallback_notexist">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/ReadDataSuccessCallback_notexist.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if ReadDataSuccessCallback::onsuccess() works properly" onload_delay="90" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P1" id="ReadDataSuccessCallback_onsuccess">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/ReadDataSuccessCallback_onsuccess.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if interface ReadStringSuccessCallback exists, it should not" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P3" id="ReadStringSuccessCallback_notexist">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/ReadStringSuccessCallback_notexist.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if ReadStringSuccessCallback::onsuccess() works properly" onload_delay="90" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P1" id="ReadStringSuccessCallback_onsuccess">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/ReadStringSuccessCallback_onsuccess.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if interface SeekSuccessCallback exists, it should not" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P3" id="SeekSuccessCallback_notexist">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/SeekSuccessCallback_notexist.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if SeekSuccessCallback::onsuccess() works properly" onload_delay="90" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P1" id="SeekSuccessCallback_onsuccess">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/SeekSuccessCallback_onsuccess.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if interface WriteStringSuccessCallback exists, it should not" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P3" id="WriteStringSuccessCallback_notexist">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/WriteStringSuccessCallback_notexist.html</test_script_entry>
+ </description>
+ </testcase>
+ <testcase purpose="Check if WriteStringSuccessCallback::onsuccess() works properly" onload_delay="90" component="TizenAPI/IO/Filesystem" execution_type="auto" priority="P1" id="WriteStringSuccessCallback_onsuccess">
+ <description>
+ <test_script_entry>/opt/tct-filesystem-tizen-tests/filesystem/WriteStringSuccessCallback_onsuccess.html</test_script_entry>
+ </description>
+ </testcase>
</set>
<set name="Filesystem_camera">
<capabilities>