Bug 1637442 [wpt PR 23551] - CookieStore: Remove secure from modification API, a=testonly
authorAyu Ishii <ayui@chromium.org>
Wed, 20 May 2020 16:59:51 +0000
changeset 531929 b9e87df182b06d430acd4321debb8702cb7148e6
parent 531928 a9d8b36b3c583a7dc505c8d6dadd880a9fa729b6
child 531930 a2b8514125f628a0ad8a62b7b7f0a902828168c2
push id37449
push userncsoregi@mozilla.com
push dateTue, 26 May 2020 02:38:57 +0000
treeherdermozilla-central@da2c7b0ac9a4 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewerstestonly
bugs1637442, 23551, 1069670, 2196805, 768043
milestone78.0a1
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Bug 1637442 [wpt PR 23551] - CookieStore: Remove secure from modification API, a=testonly Automatic update from web-platform-tests CookieStore: Remove secure from modification API This change removes `secure` option from modification API per discussion [1]. [1] https://github.com/WICG/cookie-store/issues/121 Bug: 1069670 Change-Id: I1f32016b05df4b750ccbf237e1c5de10a6ed85de Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2196805 Commit-Queue: Ayu Ishii <ayui@chromium.org> Reviewed-by: Victor Costan <pwnall@chromium.org> Cr-Commit-Position: refs/heads/master@{#768043} -- wpt-commits: c7e6980bdd001bc2f3cfec301a9464097c0b6114 wpt-pr: 23551
testing/web-platform/tests/cookie-store/cookieListItem_attributes.tentative.https.any.js
testing/web-platform/tests/cookie-store/cookieStore_delete_insecure.tentative.https.any.js
--- a/testing/web-platform/tests/cookie-store/cookieListItem_attributes.tentative.https.any.js
+++ b/testing/web-platform/tests/cookie-store/cookieListItem_attributes.tentative.https.any.js
@@ -186,34 +186,16 @@ promise_test(async testCase => {
   assert_equals(cookie.domain, null);
   assert_equals(cookie.path, currentDirectory + '/');
   assert_equals(cookie.expires, null);
   assert_equals(cookie.secure, true);
   assert_equals(cookie.sameSite, 'strict');
   assert_array_equals(Object.keys(cookie).sort(), kCookieListItemKeys);
 }, 'CookieListItem - cookieStore.set adds / to path if it does not end with /');
 
-promise_test(async testCase => {
-  await cookieStore.delete('cookie-name');
-
-  await cookieStore.set('cookie-name', 'cookie-value', { secure: false });
-  testCase.add_cleanup(async () => {
-    await cookieStore.delete('cookie-name');
-  });
-  const cookie = await cookieStore.get('cookie-name');
-  assert_equals(cookie.name, 'cookie-name');
-  assert_equals(cookie.value, 'cookie-value');
-  assert_equals(cookie.domain, null);
-  assert_equals(cookie.path, '/');
-  assert_equals(cookie.expires, null);
-  assert_equals(cookie.secure, false);
-  assert_equals(cookie.sameSite, 'strict');
-  assert_array_equals(Object.keys(cookie).sort(), kCookieListItemKeys);
-}, 'CookieListItem - cookieStore.set with secure set to false');
-
 ['strict', 'lax', 'none'].forEach(sameSiteValue => {
   promise_test(async testCase => {
     await cookieStore.delete('cookie-name');
 
     await cookieStore.set({
         name: 'cookie-name', value: 'cookie-value', sameSite: sameSiteValue });
     testCase.add_cleanup(async () => {
       await cookieStore.delete('cookie-name');
deleted file mode 100644
--- a/testing/web-platform/tests/cookie-store/cookieStore_delete_insecure.tentative.https.any.js
+++ /dev/null
@@ -1,22 +0,0 @@
-// META: title=Cookie Store API: cookieStore.delete() with insecure cookies
-// META: global=window,serviceworker
-
-'use strict';
-
-promise_test(async t => {
-  await cookieStore.set('cookie-name', 'cookie-value', { secure: false });
-  t.add_cleanup(async () => { await cookieStore.delete('cookie-name'); });
-
-  await cookieStore.delete('cookie-name');
-  const cookie = await cookieStore.get('cookie-name');
-  assert_equals(cookie, null);
-}, 'cookieStore.delete(name) can delete an insecure cookie');
-
-promise_test(async t => {
-  await cookieStore.set('cookie-name', 'cookie-value', { secure: false });
-  t.add_cleanup(async () => { await cookieStore.delete('cookie-name'); });
-
-  await cookieStore.delete({ name: 'cookie-name' });
-  const cookie = await cookieStore.get('cookie-name');
-  assert_equals(cookie, null);
-}, 'cookieStore.delete(options) can delete an insecure cookie');