-
Notifications
You must be signed in to change notification settings - Fork 306
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fixes some -A failures for Closure (#601)
- Loading branch information
Showing
3 changed files
with
75 additions
and
2 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
32 changes: 32 additions & 0 deletions
32
framework/projects/Closure/compile-errors/test-107-109.diff
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,32 @@ | ||
diff --git a/test/com/google/debugging/sourcemap/SourceMapConsumerV3Test.java b/test/com/google/debugging/sourcemap/SourceMapConsumerV3Test.java | ||
index 0364059cf..39a501b45 100644 | ||
--- a/test/com/google/debugging/sourcemap/SourceMapConsumerV3Test.java | ||
+++ b/test/com/google/debugging/sourcemap/SourceMapConsumerV3Test.java | ||
@@ -20,6 +20,7 @@ import junit.framework.TestCase; | ||
|
||
import org.json.JSONArray; | ||
|
||
+import java.util.Collection; | ||
import java.util.Map; | ||
|
||
/** | ||
@@ -41,7 +41,8 @@ public class SourceMapConsumerV3Test extends TestCase { | ||
SourceMapConsumerV3 consumer = new SourceMapConsumerV3(); | ||
consumer.parse(sourceMap); | ||
|
||
- String[] sources = (String[]) consumer.getOriginalSources().toArray(); | ||
+ Collection<String> temp = consumer.getOriginalSources(); | ||
+ String[] sources = temp.toArray(new String[0]); | ||
|
||
assertEquals(1, sources.length); | ||
assertEquals(null, consumer.getSourceRoot()); | ||
@@ -62,7 +63,8 @@ public class SourceMapConsumerV3Test extends TestCase { | ||
SourceMapConsumerV3 consumer = new SourceMapConsumerV3(); | ||
consumer.parse(sourceMap); | ||
|
||
- String[] sources = (String[]) consumer.getOriginalSources().toArray(); | ||
+ Collection<String> temp = consumer.getOriginalSources(); | ||
+ String[] sources = temp.toArray(new String[0]); | ||
|
||
assertEquals(1, sources.length); | ||
assertEquals("http://server/path/", consumer.getSourceRoot()); |
32 changes: 32 additions & 0 deletions
32
framework/projects/Closure/compile-errors/test-175-176.diff
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,32 @@ | ||
diff --git a/test/com/google/debugging/sourcemap/SourceMapConsumerV3Test.java b/test/com/google/debugging/sourcemap/SourceMapConsumerV3Test.java | ||
index 0364059cf..39a501b45 100644 | ||
--- a/test/com/google/debugging/sourcemap/SourceMapConsumerV3Test.java | ||
+++ b/test/com/google/debugging/sourcemap/SourceMapConsumerV3Test.java | ||
@@ -20,6 +20,7 @@ import junit.framework.TestCase; | ||
|
||
import org.json.JSONArray; | ||
|
||
+import java.util.Collection; | ||
import java.util.Map; | ||
|
||
/** | ||
@@ -41,7 +41,8 @@ public class SourceMapConsumerV3Test extends TestCase { | ||
SourceMapConsumerV3 consumer = new SourceMapConsumerV3(); | ||
consumer.parse(sourceMap); | ||
|
||
- String[] sources = (String[]) consumer.getOriginalSources().toArray(); | ||
+ Collection<String> temp = consumer.getOriginalSources(); | ||
+ String[] sources = temp.toArray(new String[0]); | ||
|
||
assertEquals(1, sources.length); | ||
assertEquals(null, consumer.getSourceRoot()); | ||
@@ -62,7 +63,8 @@ public class SourceMapConsumerV3Test extends TestCase { | ||
SourceMapConsumerV3 consumer = new SourceMapConsumerV3(); | ||
consumer.parse(sourceMap); | ||
|
||
- String[] sources = (String[]) consumer.getOriginalSources().toArray(); | ||
+ Collection<String> temp = consumer.getOriginalSources(); | ||
+ String[] sources = temp.toArray(new String[0]); | ||
|
||
assertEquals(1, sources.length); | ||
assertEquals("http://server/path/", consumer.getSourceRoot()); |