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

Unified Diff: sky/tests/styles/inline_style.dart

Issue 1212163009: Port remaining Sky tests to the new world (Closed) Base URL: git@github.com:domokit/mojo.git@master
Patch Set: add Created 5 years, 6 months 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « sky/tests/styles/inline-style-expected.txt ('k') | sky/tests/styles/inline_style-expected.txt » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: sky/tests/styles/inline_style.dart
diff --git a/sky/tests/styles/inline-style.sky b/sky/tests/styles/inline_style.dart
similarity index 69%
rename from sky/tests/styles/inline-style.sky
rename to sky/tests/styles/inline_style.dart
index 65091ba5b3b5756e3d1b3db549c4188b2134f3c3..cd8b6bac2dc4a80b3dfab855d8a48917a14d7184 100644
--- a/sky/tests/styles/inline-style.sky
+++ b/sky/tests/styles/inline_style.dart
@@ -1,6 +1,3 @@
-<html>
-<foo />
-<script>
import "../resources/third_party/unittest/unittest.dart";
import "../resources/unit.dart";
@@ -10,14 +7,14 @@ void main() {
initUnit();
test('should be settable using "style" attribute', () {
- var foo = document.querySelector('foo');
- foo.setAttribute('style', 'color: red');
+ LayoutRoot layoutRoot = new LayoutRoot();
+ var document = new Document();
+ var foo = document.createElement('foo');
+ layoutRoot.rootElement = foo;
+ foo.setAttribute('style', 'color: red');
expect(foo.getAttribute('style'), equals('color: red'));
expect(foo.style["color"], equals('rgb(255, 0, 0)'));
- expect(window.getComputedStyle(foo)["color"], equals('rgb(255, 0, 0)'));
});
}
-</script>
-</html>
« no previous file with comments | « sky/tests/styles/inline-style-expected.txt ('k') | sky/tests/styles/inline_style-expected.txt » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698