Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(23)

Side by Side Diff: sky/tests/mutation-observer/script-append.html

Issue 685623002: Move the tests from .html to .sky (Closed) Base URL: https://github.com/domokit/mojo.git@master
Patch Set: Created 6 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
(Empty)
1 <html>
2 <link rel="import" href="../resources/chai.html" />
3 <link rel="import" href="../resources/mocha.html" />
4 <script>
5 describe('MutationObserver', function() {
6 it('should not invoke callbacks when appending a script', function() {
7 var mutationsDelivered = false;
8 function callback(mutations) {
9 mutationsDelivered = true;
10 }
11
12 var observer = new MutationObserver(callback);
13 var div = document.createElement('div');
14 observer.observe(div, {attributes: true});
15 div.setAttribute('foo', 'bar');
16 assert.notOk(mutationsDelivered);
17 var scriptDidRun = false;
18 var script = document.createElement('script');
19 script.textContent = 'scriptDidRun = true';
20 assert.notOk(scriptDidRun);
21 document.documentElement.appendChild(script);
22 assert.notOk(scriptDidRun);
23 assert.notOk(mutationsDelivered);
24 });
25 });
26 </script>
27 </html>
OLDNEW
« no previous file with comments | « sky/tests/mutation-observer/observer-wrapper-dropoff-transient.sky ('k') | sky/tests/mutation-observer/script-append.sky » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698