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

Unified Diff: test/file_test.dart

Issue 1028813002: Introduce span with line context (Closed) Base URL: git@github.com:dart-lang/source_span.git@master
Patch Set: Created 5 years, 9 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
Index: test/file_test.dart
diff --git a/test/file_test.dart b/test/file_test.dart
index 114a17e44ba116d3895cffd270f0665c88d2f894..0ec05349ec912a1ed66a4b21a33c73cce4af5147 100644
--- a/test/file_test.dart
+++ b/test/file_test.dart
@@ -87,7 +87,7 @@ zip zap zop""", url: "foo.dart");
test("column may not be outside the file", () {
expect(() => file.getOffset(2, 100), throwsRangeError);
});
-
+
test("column may not be outside the line", () {
expect(() => file.getOffset(1, 20), throwsRangeError);
});
@@ -109,8 +109,8 @@ zip zap zop""", url: "foo.dart");
group("for span().union()", () {
test("source URLs must match", () {
- var other = new SourceSpan(
- new SourceLocation(10), new SourceLocation(11), "_");
+ var other =
+ new SourceSpan(new SourceLocation(10), new SourceLocation(11), "_");
expect(() => file.span(9, 10).union(other), throwsArgumentError);
});
@@ -306,10 +306,8 @@ zip zap zop""", url: "bar.dart").span(10, 11);
});
test("returns a base SourceSpan for a SourceSpan input", () {
- var other = new SourceSpan(
- new SourceLocation(0, sourceUrl: "foo.dart"),
- new SourceLocation(5, sourceUrl: "foo.dart"),
- "hey, ");
+ var other = new SourceSpan(new SourceLocation(0, sourceUrl: "foo.dart"),
+ new SourceLocation(5, sourceUrl: "foo.dart"), "hey, ");
var result = span.union(other);
expect(result, isNot(new isInstanceOf<FileSpan>()));
expect(result.start, equals(other.start));
@@ -367,4 +365,4 @@ zip zap zop""", url: "bar.dart").span(10, 11);
});
});
});
-}
+}
« lib/src/span.dart ('K') | « test/file_message_test.dart ('k') | test/location_test.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698