use of com.google.idea.blaze.base.model.primitives.WorkspacePath in project intellij by bazelbuild.
the class BuiltInRuleAnnotatorTest method testNoErrorsForValidStandardRule.
@Test
public void testNoErrorsForValidStandardRule() {
specProvider.setRules(ImmutableMap.of(JAVA_TEST.name, JAVA_TEST));
BuildFile file = createBuildFile(new WorkspacePath("java/com/google/BUILD"), "java_test(", " name = 'import',", " srcs = ['src'],", " neverlink = 0,", ")");
assertNoErrors(file);
}
use of com.google.idea.blaze.base.model.primitives.WorkspacePath in project intellij by bazelbuild.
the class GlobValidationTest method testNormalGlob.
@Test
public void testNormalGlob() {
BuildFile file = createBuildFile(new WorkspacePath("java/com/google/BUILD"), "glob(['**/*.java'])");
assertNoErrors(file);
}
use of com.google.idea.blaze.base.model.primitives.WorkspacePath in project intellij by bazelbuild.
the class GlobValidationTest method testAllArguments.
@Test
public void testAllArguments() {
BuildFile file = createBuildFile(new WorkspacePath("java/com/google/BUILD"), "glob(['**/*.java'], exclude = ['test/*.java'], exclude_directories = 0)");
assertNoErrors(file);
}
use of com.google.idea.blaze.base.model.primitives.WorkspacePath in project intellij by bazelbuild.
the class GlobValidationTest method testKnownInvalidResolvedString.
@Test
public void testKnownInvalidResolvedString() {
BuildFile file = createBuildFile(new WorkspacePath("java/com/google/BUILD"), "bool_literal = True", "glob([bool_literal])");
assertHasError(file, "Glob parameter 'include' must be a list of strings");
}
use of com.google.idea.blaze.base.model.primitives.WorkspacePath in project intellij by bazelbuild.
the class GlobValidationTest method testUnrecognizedArgumentError.
@Test
public void testUnrecognizedArgumentError() {
BuildFile file = createBuildFile(new WorkspacePath("java/com/google/BUILD"), "glob(['**/*.java'], exclude = ['test/*.java'], extra = 1)");
assertHasError(file, "Unrecognized glob argument");
}
Aggregations