diff options
author | cparsons <cparsons@google.com> | 2018-03-26 07:49:29 -0700 |
---|---|---|
committer | Copybara-Service <copybara-piper@google.com> | 2018-03-26 07:50:48 -0700 |
commit | 1f8ba946a3c20413ff0a95235b20d7cc1b4964f0 (patch) | |
tree | 1a6c59da1573102f87f7d90fcf92e090d0b77f76 /src/test/java/com | |
parent | f1ad0e6df1528894b4bb4b1894616340a427b6a3 (diff) |
Convert SkylarkRuleImplementationFunctions functions to use @SkylarkCallable instead.
RELNOTES: None.
PiperOrigin-RevId: 190463597
Diffstat (limited to 'src/test/java/com')
-rw-r--r-- | src/test/java/com/google/devtools/build/lib/skylark/SkylarkRuleImplementationFunctionsTest.java | 10 |
1 files changed, 4 insertions, 6 deletions
diff --git a/src/test/java/com/google/devtools/build/lib/skylark/SkylarkRuleImplementationFunctionsTest.java b/src/test/java/com/google/devtools/build/lib/skylark/SkylarkRuleImplementationFunctionsTest.java index 40744c893f..a1bbf220b0 100644 --- a/src/test/java/com/google/devtools/build/lib/skylark/SkylarkRuleImplementationFunctionsTest.java +++ b/src/test/java/com/google/devtools/build/lib/skylark/SkylarkRuleImplementationFunctionsTest.java @@ -67,9 +67,7 @@ import org.junit.rules.ExpectedException; import org.junit.runner.RunWith; import org.junit.runners.JUnit4; -/** - * Tests for SkylarkRuleImplementationFunctions. - */ +/** Tests for skylark functions relating to rule implemenetation. */ @RunWith(JUnit4.class) public class SkylarkRuleImplementationFunctionsTest extends SkylarkTestCase { @Rule public ExpectedException thrown = ExpectedException.none(); @@ -717,8 +715,8 @@ public class SkylarkRuleImplementationFunctionsTest extends SkylarkTestCase { @Test public void testRunfilesBadSetGenericType() throws Exception { checkErrorContains( - "expected depset of Files or NoneType for 'transitive_files' while calling runfiles " - + "but got depset of ints instead: depset([1, 2, 3])", + "expected value of type 'depset of Files or NoneType' for parameter 'transitive_files', " + + "in method call runfiles(depset transitive_files) of 'ctx'", "ruleContext.runfiles(transitive_files=depset([1, 2, 3]))"); } @@ -833,7 +831,7 @@ public class SkylarkRuleImplementationFunctionsTest extends SkylarkTestCase { SkylarkRuleContext ruleContext = createRuleContext("//foo:foo"); checkErrorContains( ruleContext, - "unexpected keyword 'bad_keyword' in call to runfiles(self: ctx, ", + "unexpected keyword 'bad_keyword', in method call runfiles(string bad_keyword) of 'ctx'", "ruleContext.runfiles(bad_keyword = '')"); } |