aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/test/java/com/google/devtools
Commit message (Collapse)AuthorAge
* Enable smoke tests for Java information being provided on Android rules.Gravatar Dmitry Lomov2016-02-11
| | | | | -- MOS_MIGRATED_REVID=114435744
* Add support for java_imports to Skylark IDE info aspect.Gravatar Dmitry Lomov2016-02-11
| | | | | -- MOS_MIGRATED_REVID=114434073
* Expose Java annotation processing information to Skylark.Gravatar Dmitry Lomov2016-02-11
| | | | | | | Also added some features to Skylark aspect. -- MOS_MIGRATED_REVID=114431594
* Add a few extra tests for XcodeProvider.Gravatar Lukacs Berki2016-02-11
| | | | | -- MOS_MIGRATED_REVID=114431043
* Make local_repository and new_local_repository work on Windows.Gravatar Lukacs Berki2016-02-11
| | | | | | | This makes it possible to compile //third_party/ijar with a bootstrapped Bazel on Windows in dslomov's tree. -- MOS_MIGRATED_REVID=114428109
* Allow for more flexibility in choices of Version for the ↵Gravatar Shreya Bhattarai2016-02-11
| | | | | | | GraphConcurrencyTest by allowing us to set an initial version, as well as a method to return the version's successor. -- MOS_MIGRATED_REVID=114367424
* Allow propagation of execution requirements to the ctx.resolve_command ↵Gravatar Chris Parsons2016-02-11
| | | | | | | | | function. In the case of the requires-darwin tag, /bin/bash will be used instead of an alternative, which matches the current genrule implementation. -- MOS_MIGRATED_REVID=114360408
* Allow ParallelEvaluator to not store errors alongside values if nodes ↵Gravatar Janak Ramakrishnan2016-02-11
| | | | | | | recover from errors. In the case of a single keep_going build, with no subsequent nokeep_going builds, storing the errors is unnecessary. -- MOS_MIGRATED_REVID=114355846
* Make xcode project generation generate correct filenames for external reposGravatar Kristina Chodorow2016-02-11
| | | | | -- MOS_MIGRATED_REVID=114350802
* Remove TransitivePackageLoader#getVisitedTargets, which was only used in ↵Gravatar Janak Ramakrishnan2016-02-11
| | | | | | | tests. Replace it in tests with direct Skyframe graph lookups. -- MOS_MIGRATED_REVID=114335937
* Rollback of commit df03e10f6552566982399b8779fe7bc7a17d75dc.Gravatar Michajlo Matijkiw2016-02-11
| | | | | -- MOS_MIGRATED_REVID=114329043
* Forbid overloading of a repository outside of the first part of the ↵Gravatar Damien Martin-Guillerez2016-02-11
| | | | | | | | | workspace file Fixes #824. -- MOS_MIGRATED_REVID=114326952
* Fix bug in TargetPatternList.equals, which was ignoring the offset.Gravatar Ulf Adams2016-02-11
| | | | | -- MOS_MIGRATED_REVID=114326701
* Implement TODO from: ↵Gravatar Greg Estren2016-02-11
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | https://github.com/bazelbuild/bazel/blo[]fbbd6a32b95ba746f09dae1eaeaccf675cd5b3/src/main/java/com/google/devtools/build/lib/packages/Attribute.java#L1045 This allows the default value computation for latebound attributes to consider the values of configurable attributes. This is most directly useful for user-definable Skylark defaults, which have full access to the values of all non-latebound attributes. Without this change, this kind of scenario crashes Bazel. For example: ------------------ select_rules.bzl: ------------------ def _impl(ctx): ctx.file_action( output=ctx.outputs.out_file, content=ctx.attr.string_value, ) return struct() # Bug does not manifest without using this as a default. def _derived_value(attrs, _): return Label("//some:dep") selector_rule = rule( implementation=_impl, attrs={ "string_value": attr.string(default=""), "out_file": attr.output(), "_derived": attr.label(default=_derived_value), }, output_to_genfiles=True, ) def selector_macro(name, out_file="", string_value=""): # This will fail with selectors. selector_rule( name="%s_skylark" % name, string_value=string_value, out_file=out_file + ".skylark", ) # This does not. native.genrule( name="%s_genrule" % name, cmd="echo '" + string_value + "' > $@", outs=[out_file + ".genrule"], ) native.filegroup( name=name, srcs=[":%s_genrule" % name, "%s_skylark" % name], ) ------------------ BUILD.bzl: ------------------ config_setting( name = "selector", values = {"compilation_mode": "opt"}, ) selector_macro( name = "this_rule", string_value = """soup? """ + select({ ":selector": "no, thank you.", "//conditions:default": "yes, please!!", }), out_file = "this_rule.txt", ) -- MOS_MIGRATED_REVID=114326474
* Allow load of external label in the WORKSPACE file.Gravatar Damien Martin-Guillerez2016-02-10
| | | | | | | | | | | | | | | | | Issue #824 Step 5. The only thing left to resolve issue #824 are correct handling of the following cases: - Forbidding overloading of a repository outside of the first part of the workspace file (or it will leads to incorrectness issue and the only use-case is the redefinition of the bazel_tools repository). - Better error reporting when trying to refer to a non-existent repository from the workspace file, for now it will print a SkyFrame cycle exception. -- MOS_MIGRATED_REVID=114316464
* Make implicit attribute label lookup consistent.Gravatar Brian Silverman2016-02-10
| | | | | | | | | | | | | | | Previously, as of 0c8049f5fc866d785dd83769fa6c38ecf771ba96, these labels were treated as relative to the repository of the rule in some places but not others. From the other commit's message: They [implicit attribute defaults] now all point to @bazel_tools anyway, so there is no need [to special-case them]. -- Change-Id: If337eb2579ae613ba09cab0e0c927691922c0a39 Reviewed-on: https://bazel-review.googlesource.com/#/c/2783/ MOS_MIGRATED_REVID=114313341
* Fix SkyframeLoadingPhaseRunner posting of EventBus events.Gravatar Ulf Adams2016-02-10
| | | | | | | | The TargetParsingCompleteEvent was posting the post-expansion targets, and the LoadingPhaseCompleteEvent was missing the test-suite targets. -- MOS_MIGRATED_REVID=114312273
* SkyframeLoadingPhaseRunner: implement --compile_one_dependency.Gravatar Ulf Adams2016-02-10
| | | | | | | | Also fix a bug in the LoadingPhaseRunner - we weren't printing an error for failed targets, duh! -- MOS_MIGRATED_REVID=114310591
* Move two visibility-related loading tests to BuildViewTest.Gravatar Ulf Adams2016-02-10
| | | | | -- MOS_MIGRATED_REVID=114304151
* Fix callback handling in the Skyframe-based target pattern eval.Gravatar Ulf Adams2016-02-10
| | | | | | | | Add a unit test - there is test coverage for this in RunCommandTest, but this runs much faster. -- MOS_MIGRATED_REVID=114302062
* Make unpredictable action inputs and outputs available to Actions.Gravatar Michael Thvedt2016-02-10
| | | | | -- MOS_MIGRATED_REVID=114249806
* Skyframe-based loading phase runner: report errors if a package is in error.Gravatar Ulf Adams2016-02-10
| | | | | | | | | | | | | | | | | | | | | This is a bit odd - the legacy loading phase runner reports a loading error, but no target pattern error in keep_going mode, even though it's clearly an error in the referenced target itself, rather than in its transitive closure. This happens because the target pattern eval swallows such errors in keep_going mode, and doesn't even report the error. I tried changing that, but it's a fairly large refactoring, and that code path is dead if we switch to the new one. In the Skyframe-based implementation, both keep_going and nokeep_going paths now report a target pattern error. (Note that the new code can never report a loading error, because it doesn't perform transitive loading.) The corresponding test is moved from SkyframeLoadingAndAnalysisTest to LoadingPhaseRunnerTest - we don't need any integration test setup for that. -- MOS_MIGRATED_REVID=114236897
* Add support for tags to Skylark IDE info aspect.Gravatar Dmitry Lomov2016-02-10
| | | | | -- MOS_MIGRATED_REVID=114234447
* Add JavaSkylarkApiProvider to all Java rules.Gravatar Dmitry Lomov2016-02-10
| | | | | -- MOS_MIGRATED_REVID=114232294
* Fix NPE in TestsInSuiteFunction.Gravatar Ulf Adams2016-02-10
| | | | | | | | Note that this only affects the new Skyframe-based implementation of the LoadingPhaseRunner, which isn't live yet. -- MOS_MIGRATED_REVID=114230017
* Properly report loading errors during configuration creation.Gravatar Ulf Adams2016-02-10
| | | | | | | | | | | | | | | | | This only applies to interleaved loading and analysis - the production code is fine. Add tests for the RedirectChaser, the fdoOptimize code path, the XcodeConfig, and the Jvm loader. Unfortunately, the configuration factory we internally create by default contains a mock Jvm loader implementation. Since that is one Yak too many right now, I'm adding a temporary method to the AnalysisMock. I added the tests to BuildViewTest for now; technically, they ought to go into the language-specific test cases, but that would require more refactoring as those don't currently run with interleaved loading and analysis. -- MOS_MIGRATED_REVID=114221476
* Update FileSystemValueChecker to handle TreeArtifact values.Gravatar Michael Thvedt2016-02-10
| | | | | -- MOS_MIGRATED_REVID=114202845
* Add tests for Label.resolveRepositoryRelative.Gravatar Brian Silverman2016-02-10
| | | | | | | -- Change-Id: I15bd47b6cb947aa1b07ab7a43eea57f3c37696d2 Reviewed-on: https://bazel-review.googlesource.com/#/c/2700/ MOS_MIGRATED_REVID=114202706
* Remove duplicate skyframe executor in SkyframeLabelVisitorTestCase.Gravatar Janak Ramakrishnan2016-02-09
| | | | | -- MOS_MIGRATED_REVID=114199687
* Unify tests for native and Skylark IntelliJ aspects.Gravatar Dmitry Lomov2016-02-09
| | | | | | | | Most tests are disabled for Skylark aspect. I'll reenable them as we get to parity. -- MOS_MIGRATED_REVID=114175091
* Support for handling TreeArtifact metadata and returning TreeArtifacts from ↵Gravatar Michael Thvedt2016-02-09
| | | | | | | ArtifactFunction. -- MOS_MIGRATED_REVID=114174899
* Rename MiddlemanExpander to ArtifactExpander, and refactor it to yield ↵Gravatar Michael Thvedt2016-02-09
| | | | | | | ArtifactFiles. -- MOS_MIGRATED_REVID=114166208
* Introduce TreeArtifact and associated code to work with it. No functionality ↵Gravatar Michael Thvedt2016-02-09
| | | | | | | implemented yet. -- MOS_MIGRATED_REVID=114157140
* Don't check direct deps when doing change pruning. Since dependents of a ↵Gravatar Janak Ramakrishnan2016-02-09
| | | | | | | node don't have access to its dependencies ("grandparents don't know grandchildren", or vice versa, depending on your point of view), changes to a node's dependencies can't affect downstream nodes. -- MOS_MIGRATED_REVID=114143894
* Implement ide-resolve output group in IntelliJ info aspect.Gravatar Dmitry Lomov2016-02-09
| | | | | -- MOS_MIGRATED_REVID=114124584
* Add supportsDynamicLinker to CppConfigurationGravatar Googler2016-02-09
| | | | | | | | | Rather than a new protobuf field, this enabling flag is presence of a section with DYNAMIC linking mode in the CROSSTOOL file, whether or not it needs to specify any linker flags. RELNOTES[NEW]: Better support for toolchains that don't have a dynamic linker. -- MOS_MIGRATED_REVID=114110200
* Expose JavaRuleOutputJarsProvider to Skylark and utilize it in ide info aspect.Gravatar Dmitry Lomov2016-02-09
| | | | | -- MOS_MIGRATED_REVID=114104006
* Mark //src/test/java/com/google/devtools/build/lib:shell_test as flaky.Gravatar David Chen2016-02-07
| | | | | | | Issue #248 -- MOS_MIGRATED_REVID=113990796
* WorkspaceASTFunction returns a list of ASTs so we can split the AST before ↵Gravatar Damien Martin-Guillerez2016-02-07
| | | | | | | | | load statements Issue #824 Step 2. -- MOS_MIGRATED_REVID=113986176
* Add an intermediate SkyFunction for resolving the external packageGravatar Damien Martin-Guillerez2016-02-07
| | | | | | | | | | | | | | The WORKSPACE file parsing needs to be separated into several parts to enable load of labels in the WORKSPACE file. This change adds an intermediate SkyFunction, ExternalPackageFunction, that requires all the WORKSPACE file part to be parsed to resolve //external: labels. Issue #824 Step 1. -- MOS_MIGRATED_REVID=113984026
* Add Truth subject for ErrorInfo and improve one for EvaluationResult.Gravatar Janak Ramakrishnan2016-02-05
| | | | | -- MOS_MIGRATED_REVID=113911470
* Move ObjC compilation actions for J2ObjC-translated code from binary level ↵Gravatar Rumou Duan2016-02-05
| | | | | | | | | | | | to the edges (J2ObjcAspect and J2ObjcProtoAspect). RELNOTES[INC]: ObjC compile actions for J2ObjC-translated code now only has access to headers from the java deps of the associated original java rule. These compile actions no longer takes the compiler options specified in "copts" attribute on objc_binary/ios_test rules. J2ObjC dead code removal (enabled through flag "--j2objc_dead_code_removal") now happens *after* ObjC compilation. -- MOS_MIGRATED_REVID=113910545
* Move the Globber interface into its own file.Gravatar Nathan Harmata2016-02-05
| | | | | -- MOS_MIGRATED_REVID=113893917
* Make Skylark "license"-type attributes non-configurable.Gravatar Greg Estren2016-02-05
| | | | | | | | | Bazel has custom loading-phase logic checking "licenses" attributes. Without this change, that logic fails with a "licenses is potentially configurable" error. -- MOS_MIGRATED_REVID=113890489
* Add jdeps support to AndroidStudioInfoAspect.Gravatar Googler2016-02-04
| | | | | | | This can be used for classpath reduction on the IDE side. -- MOS_MIGRATED_REVID=113861117
* Allow switching on header processing (parse_headers or preprocess_headers)Gravatar Manuel Klimek2016-02-04
| | | | | | | | | | | for targets in the transitive closure of a target that is built. Rollback of commit e01291a1a3d65cd706190c9bf0c8cfc585f38eb7. Added an additional test to check that the configuration value is actually effectively used. -- MOS_MIGRATED_REVID=113836105
* Add additional inputs as compilation prerequisites. Tools that buildGravatar Manuel Klimek2016-02-04
| | | | | | | | | | with --compilation_prerequisites_only do rely on all prerequisites being available. RELNOTES: Make C++ modules compatible with tools using --compilation_prerequisites_only -- MOS_MIGRATED_REVID=113829249
* Add support for downloading .tar.xz files to http_archive rules.Gravatar David Chen2016-02-04
| | | | | | | | | Fixes #845 RELNOTES: Add support for .tar.xz archives to http_archive rules. -- MOS_MIGRATED_REVID=113829042
* Fix configuration error handling for the interleaved case.Gravatar Ulf Adams2016-02-04
| | | | | | | | In the interleaved case, loading errors can occur during configuration creation and we need to correctly report such errors in that case. -- MOS_MIGRATED_REVID=113826273
* Have GlobFunction make use of the assumption that the glob's package exists ↵Gravatar Nathan Harmata2016-02-04
| | | | | | | | | by having it not declare a dep on the PackageLookupValue for the package. This optimization means that a BUILD file edit doesn't (necessarily) invalidate all the globs in the package; the PackageLookupValue node would get change-pruned but we still pay the very small cost of invalidating unnecessarily. Also slightly improve variable naming in GlobFunctionTest. -- MOS_MIGRATED_REVID=113799936