Navigation Menu

Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

IndexedDB cursor.request #15820

Merged
merged 3 commits into from Mar 19, 2019

Conversation

jakearchibald
Copy link
Contributor

No description provided.

Copy link
Contributor

@inexorabletash inexorabletash left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please add test cases for:

  • IDBCursorWithValue (i.e. non-key cursor)
  • Both cursor types with source from index (test here has object store as source)
  • Value of cursor.request not within IDB callback and after transaction has ended. (Should still be valid, but one could imagine a non-conforming implementation that needs to break a reference cycle and nulls it out.)

assert_readonly(cursor, 'request');
});
},
document.title
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Remove.

const cursor = req.result;
assert_equals(cursor.request, req, 'cursor.request');
assert_readonly(cursor, 'request');
});
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Needs t.done();

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Haha I did this right in my run through before cameras were on. Oh well.

@@ -0,0 +1,27 @@
<!DOCTYPE html>
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Make this a .any.js test for more coverage?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

... and remove some boilerplate.

@jakearchibald
Copy link
Contributor Author

@inexorabletash done!

Copy link
Contributor

@inexorabletash inexorabletash left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

More nits!

Looking awesome though.

IndexedDB/idbcursor-request.any.js Show resolved Hide resolved
}), 0);
});

req.transaction.onerror = t.step_func((event) => {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This can use t.unreached_func instead for brevity.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is what I get for cargo culting the other tests.

inexorabletash pushed a commit to w3c/IndexedDB that referenced this pull request Mar 14, 2019
Define new |request| attribute on IDBCursor. Discussed in #255

WPT PR ready to land: web-platform-tests/wpt#15820

Implementations pending, but this should be fairly straightforward so going ahead with landing this (and tests) optimistically.
@inexorabletash
Copy link
Contributor

Hmmm, any idea how to get the "Taskcluster (pull_request)" to finish? @Hexcles @foolip

@foolip
Copy link
Member

foolip commented Mar 15, 2019

@inexorabletash looks like it hasn't even started. @jgraham we've had this issue before in #14165 which was then resolved, but now it's happening again. Do you know of ongoing Taskcluster issues?

The easiest way to retrigger all CI systems is to close and reopen a PR, so I'll do that. If Taskcluster still doesn't start, we should just admin merge.

@foolip
Copy link
Member

foolip commented Mar 15, 2019

This is concerning, there's still no "Details" link for Taskcluster, so it hasn't told GitHub about any ongoing run. @jgraham, absent that, is there any way to figure out if Taskcluster started?

@inexorabletash
Copy link
Contributor

Admin-merge pls?

@Hexcles
Copy link
Member

Hexcles commented Mar 19, 2019

Given that even the close-reopen trick didn't work, I'm admin-merging this. Debugging the infra shouldn't block developers' work.

@Hexcles Hexcles merged commit e4a3e27 into web-platform-tests:master Mar 19, 2019
@jakearchibald jakearchibald deleted the cursor-request branch April 16, 2019 15:16
marcoscaceres pushed a commit that referenced this pull request Jul 23, 2019
* cursor.request

* More detailed test, testing the various different kinds of cursor.

* Using unreached_func
inexorabletash pushed a commit to w3c/IndexedDB that referenced this pull request Feb 1, 2021
Define new |request| attribute on IDBCursor. Discussed in #255

WPT PR ready to land: web-platform-tests/wpt#15820

Implementations pending, but this should be fairly straightforward so going ahead with landing this (and tests) optimistically.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

6 participants