Skip to content

IndexedDB: Add test for commit order of empty transactions #3154

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

Merged
merged 3 commits into from
Jun 21, 2016
Merged

IndexedDB: Add test for commit order of empty transactions #3154

merged 3 commits into from
Jun 21, 2016

Conversation

inexorabletash
Copy link
Contributor

As noted in w3c/IndexedDB#77 it is expected that "empty" transactions (no requests filed) still complete with the same ordering requirements as transactions with requests. Specifically, if transaction A is created after a read/write transaction B with overlapping scope, A should complete after B completes.

@wpt-pr-bot
Copy link
Collaborator

Reviewers for this pull request are: @velmont, @chunywang, @dumbmatter, @inexorabletash, @yunxiaoxie, @zhaozihao, and @zqzhang.

@hoppipolla-critic-bot
Copy link

Critic review: https://critic.hoppipolla.co.uk/r/6609

This is an external review system which you may optionally use for the code review of your pull request.

In order to help critic track your changes, please do not make in-place history rewrites (e.g. via git rebase -i or git commit --amend) when updating this pull request.

@inexorabletash
Copy link
Contributor Author

@bevis-tseng - can you review this?

tx3.oncomplete = t.step_func(() => saw('tx3.oncomplete'));

var rq2 = store.put('b', 2);
rq2.onsuccess = () => t.step_func(saw('rq2.onsuccess'));
Copy link

@bevis-tseng bevis-tseng Jun 15, 2016

Choose a reason for hiding this comment

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

LGTM except line#84 in transaction-lifetime-empty.html.
Is it intended? IMO, It's more proper to be:
rq2.onsuccess = t.step_func(() => saw('rq2.onsuccess'));

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Whoops, thanks. Will fix.

@inexorabletash inexorabletash merged commit 8f17185 into web-platform-tests:master Jun 21, 2016
@inexorabletash inexorabletash deleted the indexeddb-empty-tx branch June 21, 2016 16:14
ivanzr pushed a commit to ivanzr/web-platform-tests that referenced this pull request Jun 29, 2016
…orm-tests#3154)

Tracked by w3c/IndexedDB#77

Ensure that a transaction with no requests filed against it still completes
in the same order as a transaction with requests (i.e. after previous
readwrite transactions with overlapping scope).
ddorwin pushed a commit to ddorwin/web-platform-tests that referenced this pull request Sep 13, 2016
…orm-tests#3154)

Tracked by w3c/IndexedDB#77

Ensure that a transaction with no requests filed against it still completes
in the same order as a transaction with requests (i.e. after previous
readwrite transactions with overlapping scope).
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.

4 participants