[webnfc] nfc.push should throw TimeoutError when timer expires
Reported by
canx....@intel.com,
Apr 21 2017
|
||||||
Issue descriptionSteps to reproduce the problem: Test case: https://thewebera.github.io/web-test-suite/web-nfc/nfc/nfc_push_exceptions.https.html Test name: nfc.push should fail with TimeoutError when timer expires. 1.Set the invalid timeout value, e.g. navigator.nfc.push(“test”, { timeout: "1"}) What is the expected behavior? Test should fail with TimeoutError. What went wrong? No error thrown. Did this work before? N/A Does this work in other browsers? N/A Chrome version: 60.0.3074.0 Channel: canary OS Version: Nexus 7(Android 5.1) Flash Version: Shockwave Flash 25.0 r0 According to the spec: https://w3c.github.io/web-nfc/#the-push-method Description: If timer expires, reject promise with "TimeoutError" and abort these steps.
,
Apr 21 2017
,
Apr 24 2017
,
Apr 28 2017
,
May 2 2017
@alexander.shalamov, My steps to reproduce the problem is ambiguous, so I
update description of the steps to reproduce problem:
Change "Set the invalid timeout value, e.g. navigator.nfc.push(“test”, { timeout: "1"})" to
"Set timeout with timer expires value, e.g. navigator.nfc.push(“test”, { timeout: 1})".
Sorry, this is my mistake.
Thanks!
,
May 4 2017
The following revision refers to this bug: https://chromium.googlesource.com/chromium/src.git/+/b49d34931454bc1fdffdba99d6a0b344430746b5 commit b49d34931454bc1fdffdba99d6a0b344430746b5 Author: alexander.shalamov <alexander.shalamov@intel.com> Date: Thu May 04 08:44:57 2017 [webnfc] Cancel nfc.push operation when timeout expires This CL adds missing timeout handling functionality [1]. When user provides timeout value for the push operation, and NFC tag is not in proximity for the duration of timeout value, operation must be rejected with timeout error. Unit test is added to test new functionality. https://w3c.github.io/web-nfc/#the-push-method (Step 14). BUG= 714037 Review-Url: https://codereview.chromium.org/2851453004 Cr-Commit-Position: refs/heads/master@{#469294} [modify] https://crrev.com/b49d34931454bc1fdffdba99d6a0b344430746b5/device/nfc/android/java/src/org/chromium/device/nfc/NfcImpl.java [modify] https://crrev.com/b49d34931454bc1fdffdba99d6a0b344430746b5/device/nfc/android/junit/src/org/chromium/device/nfc/NFCTest.java
,
May 4 2017
,
May 4 2017
canx.cao@ Could you please verify? Thanks.
,
May 4 2017
OK, I will verify it once the fix landed in new Chrome.
,
May 10 2017
I retest this issue with chrome 60.0.3094.0, it has been fixed. Close.
,
May 10 2017
|
||||||
►
Sign in to add a comment |
||||||
Comment 1 by canx....@intel.com
, Apr 21 2017