aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/test
Commit message (Collapse)AuthorAge
* Skip the bazel_toolchain_test on Darwin machine. Fixes #1838.Gravatar Xin Gao2016-09-30
| | | | | -- MOS_MIGRATED_REVID=134701835
* Export idl_import_root to Android Studio, so that we know the packages of ↵Gravatar Googler2016-09-30
| | | | | | | new AIDL files in relation to their location. -- MOS_MIGRATED_REVID=134687843
* Add an actions provider for testing Skylark rules.Gravatar Jon Brandvein2016-09-30
| | | | | | | The new provider gathers actions generated by any Skylark-based RuleConfiguredTarget, so long as the rule definition has _skylark_test=True set. For the moment this flag is under the user's control, but the intention is that it will be set by a test runner. -- MOS_MIGRATED_REVID=134687396
* Fixed location expansion in cc rules.Gravatar Vladimir Moskva2016-09-30
| | | | | -- MOS_MIGRATED_REVID=134652924
* Make action_env_test parametric in the product nameGravatar Klaus Aehlig2016-09-29
| | | | | -- MOS_MIGRATED_REVID=134636896
* Optimize how null configurations get created and add test infrastructure for ↵Gravatar Greg Estren2016-09-29
| | | | | | | | | | | | Bazel's dep configuration creation logic. This essentially implements the following TODOs: https://github.com/bazelbuild/bazel/blob/bc6045dcc8fa33d4241d231138020ac4bdecc14f/src/main/java/com/google/devtools/build/lib/skyframe/ConfiguredTargetFunction.java#L599 https://github.com/bazelbuild/bazel/blob/bc6045dcc8fa33d4241d231138020ac4bdecc14f/src/test/java/com/google/devtools/build/lib/skyframe/ConfigurationsForTargetsTest.java#L42 -- MOS_MIGRATED_REVID=134607049
* Fix IDE aspect crash when traversing a data mode deps attr.Gravatar Googler2016-09-29
| | | | | -- MOS_MIGRATED_REVID=134566270
* Allow new_ rules to overwrited BUILD files in downloaded reposGravatar Kristina Chodorow2016-09-28
| | | | | | | | | | | My previous change carefully checked that the file was a symlink before removing it and added a test with local repositories... and it of course isn't a symlink with downloaded repositories and crashes. Fixes #1697. -- MOS_MIGRATED_REVID=134536130
* Windows, native: add windows_msvc config_settingGravatar Laszlo Csomor2016-09-28
| | | | | | | | | | | | | | | Update `select` statements in BUILD files with the new config_setting. This is a first step on a long path that leads to us being able to compile bazel on Windows with --cpu=x64_windows_msvc. Needless to say, we're not there yet. Tested: on Linux, Darwin, Windows/MSYS -- MOS_MIGRATED_REVID=134534613
* Eliminates performance overhead of --experimental_dynamic_configs=notrim.Gravatar Greg Estren2016-09-28
| | | | | | | | | | | | | | Before this change, a non-trivial real-world build was measured to have about 20% analysis time overhead. After, that's theoretically down to 2.4%. But that's only the analysis phase, so the impact on full builds is smaller. And the impact on analysis-cached builds is zero. And practical tests show no obvious difference (JProfiler is probably overstating the impact since it excludes known heavyweight methods). The improvements, in short: - Optimize a sanity check that expects each <Attribute, Label> pair to only have one transition. This alone was over half the original performance penalty. - Simplify logic for null configuration deps (of which there are many, e.g.: all source files) - Skip a check for required fragments not available in the configuration. This is irrelevant for notrim mode. There are still some places we could optimize. Dependency.withNullConfiguration in particular takes measurable time (I think from being constructed all the time and in its hashCode calls). But this doesn't seem pressing given the new numbers. -- MOS_MIGRATED_REVID=134533452
* Add support for sandboxing persistent workers.Gravatar Philipp Wollermann2016-09-28
| | | | | -- MOS_MIGRATED_REVID=134523222
* Skylark: Give more detailed errors when parsing the argumentsGravatar Pedro Liberal Fernandez2016-09-28
| | | | | | | | | | | | | | | | | | | | | of a SkylarkCallable. CL already reviewed in commit 5972bee6ebfa53cf165befab9fa7962e19d5f620. Rolled back due to casting error in Java 1.7. This is fixed now: https://github.com/bazelbuild/bazel/issues/1832 Old: matchingMethod = new Pair<>( method, argumentListConversionResult.getArguments()); New: matchingMethod = new Pair<MethodDescriptor, List<Object>>( method, argumentListConversionResult.getArguments()); -- MOS_MIGRATED_REVID=134503884
* Remove bazel references to PB2 CPP runtime lib.Gravatar Sergio Campama2016-09-28
| | | | | -- MOS_MIGRATED_REVID=134499729
* patch bootclasspath to allow javac to compile lambdas and method references ↵Gravatar Googler2016-09-28
| | | | | | | in android_* targets (behind existing flag). -- MOS_MIGRATED_REVID=134453743
* Disallow mutation of values being iterated by a for loop or comprehensionGravatar Jon Brandvein2016-09-28
| | | | | | | | | This entails adding a read-locking mechanism to Mutability contexts. RELNOTES[INC]: Updating list/dicts while they are being looped over is not allowed. Use an explicit copy if needed ("for x in list(mylist):"). -- MOS_MIGRATED_REVID=134442701
* Fixed EvaluationProgressReceiver object namesGravatar Googler2016-09-27
| | | | | | | | | | EvaluationProgressReceiver objects have two common naming schemes currently, and calling them invalidationReceiver is misleading, so to make the naming convention standard, all object names are based on "progressReceiver." -- MOS_MIGRATED_REVID=134411011
* Refactor SkyframeExecutor#preparePackageLoading to pass all ↵Gravatar Janak Ramakrishnan2016-09-27
| | | | | | | | | PackageCacheOptions as a bundle. This will allow me to thread a new flag through more easily in the future. -- MOS_MIGRATED_REVID=134406676
* Fixed ISE while looking for cycles in WORKPLACE files #1793Gravatar Vladimir Moskva2016-09-27
| | | | | -- MOS_MIGRATED_REVID=134403060
* Add a regression test for commit 78b9cab45de2a32158cd4306cd40208045cf6f85.Gravatar Googler2016-09-27
| | | | | | | As suggested by klimek in the review (I had already submitted at that point). I confirmed that this test fails if I undo commit 78b9cab45de2a32158cd4306cd40208045cf6f85. -- MOS_MIGRATED_REVID=134400910
* Allow aspects to propagate to all attributes.Gravatar Dmitry Lomov2016-09-27
| | | | | -- MOS_MIGRATED_REVID=134378592
* Rollback of commit 5972bee6ebfa53cf165befab9fa7962e19d5f620.Gravatar Yun Peng2016-09-26
| | | | | | | | | | | | | | *** Reason for rollback *** Break Bazel bootstrap on JDK7 *** Original change description *** Skylark: Give more detailed errors when parsing the arguments of a SkylarkCallable. -- MOS_MIGRATED_REVID=134309621
* Fix an issue where a "build" command might hang after it finished, because ↵Gravatar Philipp Wollermann2016-09-26
| | | | | | | sandbox directories could not be cleaned up. -- MOS_MIGRATED_REVID=134286101
* Correctly declare direct dependenciesGravatar Klaus Aehlig2016-09-26
| | | | | | | ...instead of pulling in symbols from indirect dependencies. -- MOS_MIGRATED_REVID=134283492
* sandbox: Fix an issue where an IOException happening during ↵Gravatar Philipp Wollermann2016-09-26
| | | | | | | SandboxExecRoot#copyOutputs could hide an earlier ExecException from SandboxRunner#run in the Darwin and Linux sandbox strategies. -- MOS_MIGRATED_REVID=134273806
* Skylark: Give more detailed errors when parsing the argumentsGravatar Pedro Liberal Fernandez2016-09-26
| | | | | | | of a SkylarkCallable. -- MOS_MIGRATED_REVID=134266707
* Native declared providers are automatically exported.Gravatar Dmitry Lomov2016-09-26
| | | | | -- MOS_MIGRATED_REVID=134221884
* Introduce MoreFutures#waitForAllInterruptiblyFailFast and use this in the ↵Gravatar Nathan Harmata2016-09-26
| | | | | | | | | places we wait for tasks (plural!) submitted to a ForkJoinPool to finish since we actually want to do so interruptibly. As was to be expected, testing this was tricky :) -- MOS_MIGRATED_REVID=134128019
* Add execution permission to toolchain wrapper scripts.Gravatar Xin Gao2016-09-26
| | | | | -- MOS_MIGRATED_REVID=134120579
* RELNOTES: Allow different default mallocs per configuration.Gravatar Googler2016-09-26
| | | | | -- MOS_MIGRATED_REVID=134116487
* Add bitcode handling to swift_libraryGravatar Dmitry Shevchenko2016-09-26
| | | | | -- MOS_MIGRATED_REVID=134110312
* Chunk large stdout/err writes in RpcOutputStreamGravatar Michajlo Matijkiw2016-09-26
| | | | | | | Prevents overly large responses from overwhelming grpc. -- MOS_MIGRATED_REVID=134083479
* Revert creating a convenience symlink usiing the workspace nameGravatar Kristina Chodorow2016-09-26
| | | | | | | | | | Switch back to using the directory name, since there's no good way to get the workspace name from `clean` (yet). Fixes #1795. -- MOS_MIGRATED_REVID=134083065
* Split the workspace status keys into stable and volatile parts based on if ↵Gravatar Lukacs Berki2016-09-23
| | | | | | | | | they are prefixed with STABLE_. Fixes #1758 . -- MOS_MIGRATED_REVID=134058125
* Fixed symbolic link and hard link path not stripped when "strip_prefix" is set.Gravatar Xin Gao2016-09-23
| | | | | -- MOS_MIGRATED_REVID=134005484
* Rollback of commit 5c548f11e20c0b75203e9fe4ab682ed0418064cf.Gravatar Carmi Grushko2016-09-23
| | | | | | | | | | | | | | | | | | | | | | | *** Reason for rollback *** Fixed depot issues. *** Original change description *** Automated [] rollback of commit 2e5ec0fd99ac4bfd930da99f6089dc5faf778464. *** Reason for rollback *** Breaks some targets in the nightly: see [] *** Original change description *** Make java_proto_library's strict_deps default to true. Remove package-level attribute to set the default of strict_deps. Change the semantics to --strict_deps_java_protos to mean force strict deps of all Java protos to be true regardless of their strict_deps attribute. -- MOS_MIGRATED_REVID=133981754
* Implementation of maven_jar rule in Skylark.Gravatar Jingwen Chen2016-09-23
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | **Experimental** This is an initial implementation of the maven_jar rule in Skylark, targeted at the FRs in issue #1410. Implemented a wrapper around the maven binary to pull dependencies from remote repositories into a directory under {output_base}/external. Attributes `name`, `artifact`, `repository`, `sha1` have been implemented, but not `server`. Caveat: this rule assumes that the Maven dependency is installed in the system. Hence, the maven_skylark_test integration tests are tagged with "manual" and commented out because the Bazel CI isn't configured with the Maven binary yet. Added a serve_not_found helper for 404 response tests. Usage: ``` load("@bazel_tools//tools/build_defs/repo:maven_rules.bzl", "maven_jar") maven_jar( name = "com_google_guava_guava", artifact = "com.google.guava:guava:18.0", sha1 = "cce0823396aa693798f8882e64213b1772032b09", repository = "http://uk.maven.org/maven2", ) ``` With regards to server, there are some limitations with retrieving a maven_server's attribute at Loading Phase without the use of hacky macros (issue #1704), and even if macros are used, the maven_server is not treated as an actual dependency by maven_jar. There is a test (`test_unimplemented_server_attr`) to ensure that the error message to shown to users if they use the server attribute with this rule. -- Change-Id: I167f9d13835c30be971928b4cc60167a8e396893 Reviewed-on: https://bazel-review.googlesource.com/c/5770 MOS_MIGRATED_REVID=133971809
* Rollback of commit 4e2f75d8e60020f13a7df452488ec4cc7a719f03.Gravatar Kristina Chodorow2016-09-22
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | *** Reason for rollback *** This is causing external_integration_test to fail See, for example, http://ci.bazel.io/job/bazel-tests/BAZEL_VERSION=HEAD,PLATFORM_NAME=linux-x86_64/236/console: ** test_http_archive_tar_xz **************************************************** GET /fox.tar.xz HTTP/1.1 User-Agent: Java/1.8.0_101 Host: localhost:36541 Accept: text/html, image/gif, image/jpeg, *; q=.2, */*; q=.2 Connection: keep-alive cat: bazel-out/../external/endangered/fox/male_absolute: No such file or directory -- Test log: ----------------------------------------------------------- INFO: Reading 'startup' options from /home/ci/.cache/bazel/_bazel_ci/a761298a0949227106f79c62c3bebb6e/bazel-sandbox/81f51af6-eb50-417e-8f8d-b7bba207ee83-661/execroot/linux-x86_64/_tmp/external_integration_test_2/bazelrc: --output_user_root=/home/ci/.cache/bazel/_bazel_ci/a761298a0949227106f79c62c3bebb6e/bazel-sandbox/81f51af6-eb50-417e-8f8d-b7bba207ee83-661/execroot/linux-x86_64/_tmp/external_integration_test_2/root --host_javabase=/home/ci/.cache/bazel/_bazel_ci/a761298a0949227106f79c62c3bebb6e/bazel-sandbox/81f51af6-eb50-417e-8f8d-b7bba207ee83-661/execroot/linux-x86_64/bazel-out/local-fastbuild/bin/src/test/shell/bazel/external_integration_test.runfiles/local_jdk INFO: $TEST_TMPDIR defined: output root default is '/home/ci/.cache/bazel/_bazel_ci/a761298a0949227106f79c62c3bebb6e/bazel-sandbox/81f51af6-eb50-417e-8f8d-b7bba207ee83-661/execroot/linux-x86_64/_tmp/external_integration_test_2'. .............................................. ____Loading package: zoo ____Loading... ____Loading package: @bazel_tools//tools/cpp ____Loading package: @bazel_tools//tools/jdk ____Loading package: @local_config_xcode// ____Loading package: @local_jdk// ____Loading package: @local_config_cc// ____Loading complete. Analyzing... ____Downloading from [] 0B ____Downloading from [] 1KB ____Loading package: @endangered//fox ____Found 1 target... ____Building... ____[0 / 1] BazelWorkspaceStatusAction stable-status.txt ____[0 / 4] Creating source manifest for //zoo:breeding-program ____[0 / 4] Symlinking //zoo:breeding-program ____[3 / 4] Creating runfiles tree bazel-out/local-fastbuild/bin/zoo/breeding-program.runfiles ____Building complete. Target //zoo:breeding-program up-to-date: bazel-bin/zoo/breeding-program ____Elapsed time: 6.903s, Critical Path: 0.04s ____Running command line: bazel-bin/zoo/breeding-program Fraka-kaka-kaka-kaka-kow ------------------------------------------------------------------------ test_http_archive_tar_xz FAILED: Expected regexp #!/bin/bash echo Fraka-kaka-kaka-kaka-kow not found in bazel-out/../external/endangered/fox/male_absolute . /home/ci/.cache/bazel/_bazel_ci/a761298a0949227106f79c62c3bebb6e/bazel-sandbox/81f51af6-eb50-417e-8f8d-b7bba207ee83-661/execroot/linux-x86_64/bazel-out/local-fastbuild/bin/src/test/shell/bazel/external_integration_test.runfiles/io_bazel/src/test/shell/bazel/external_integration_test:154: in call to assert_files_same /home/ci/.cache/bazel/_bazel_ci/a761298a0949227106f79c62c3bebb6e/bazel-sandbox/81f51af6-eb50-417e-8f8d-b7bba207ee83-661/execroot/linux-x86_64/bazel-out/local-fastbuild/bin/src/test/shell/bazel/external_integration_test.runfiles/io_bazel/src/test/shell/bazel/external_integration_test:150: in call to http_archive_helper /home/ci/.cache/bazel/_bazel_ci/a761298a0949227106f79c62c3bebb6e/bazel-sandbox/81f51af6-eb50-417e-8f8d-b7bba207ee83-661/execroot/linux-x86_64/bazel-out/local-fastbuild/bin/src/test/shell/bazel/external_integration_test.runfiles/io_bazel/src/test/shell/bazel/external_integration_test:190: in call to test_http_archive_tar_xz FAILED: test_http_archive_tar_xz *** Original change description *** Fixed symbolic link and hard link path not stripped when "strip_prefix" is set. -- MOS_MIGRATED_REVID=133970692
* Fix Windows JDK7 testsGravatar Kristina Chodorow2016-09-22
| | | | | | | | | | | | | | They're accessing non-final variables in inner classes, e.g.,: src\test\java\com\google\devtools\build\lib\packages\BuildTypeTest.java:425: error: local variable result is accessed from within inner class; needs to be declared final result.add(label); (From http://ci.bazel.io/view/Bazel%20bootstrap%20and%20maintenance/job/Bazel/JAVA_VERSION=1.7,PLATFORM_NAME=windows-x86_64/845/consoleFull). Not sure how this is working on Linux/OS X JDK7. -- MOS_MIGRATED_REVID=133967835
* Push missing testdata directory to Github.Gravatar Xin Gao2016-09-22
| | | | | -- MOS_MIGRATED_REVID=133949075
* Rollback of commit 2e5ec0fd99ac4bfd930da99f6089dc5faf778464.Gravatar Tobias Werth2016-09-22
| | | | | | | | | | | | | | | *** Reason for rollback *** Breaks some targets in the nightly: see [] *** Original change description *** Make java_proto_library's strict_deps default to true. Remove package-level attribute to set the default of strict_deps. Change the semantics to --strict_deps_java_protos to mean force strict deps of all Java protos to be true regardless of their strict_deps attribute. -- MOS_MIGRATED_REVID=133938648
* Split dynamic configurations mode into:Gravatar Greg Estren2016-09-22
| | | | | | | | | | | | | | | --experimental_dynamic_configs=off - don't use dynamic configs --experimental_dynamic_configs=on - use dynamic configs with trimmed fragments --experimental_dynamic_configs=notrim - use dynamic configs with all fragments This lets us decouple two independent dimensions of dynamic configurations: 1) being able to trigger new configurations and transitions anywhere and 2) only including the fragments needed by a target's transitive closure. 2) is likely to take much more time and effort to properly finesse (three notable challenges: late-bound attributes, aspects, and dynamic shedding of output path names). But 1) by itself already yields significant benefits. So in the name of starting to shift the config work from backend theory to stuff real builds actually use, this change lets us focus on productionizing 1) without blocking on getting all of 2) working first. tl;dr: iterable deployment and all that. -- MOS_MIGRATED_REVID=133874661
* Be honest about type in Type#visitLabelsGravatar Michajlo Matijkiw2016-09-22
| | | | | | | | | | We avoided referencing Label directly, but as the code evolved it became inevitable. Also fix a typo I introduced earlier. -- MOS_MIGRATED_REVID=133831955
* Allow passing None to SkylarkCallables with 'noneable = true'Gravatar Googler2016-09-22
| | | | | | | | | | Currently, you will get an error for nearly all types since None is not contained in any type but NoneType and Object. Instead, use the same approach as SkylarkSignatureProcessor does currently. -- MOS_MIGRATED_REVID=133821662
* Make java_proto_library's strict_deps default to true.Gravatar Carmi Grushko2016-09-21
| | | | | | | | Remove package-level attribute to set the default of strict_deps. Change the semantics to --strict_deps_java_protos to mean force strict deps of all Java protos to be true regardless of their strict_deps attribute. -- MOS_MIGRATED_REVID=133789725
* Remove absolute paths from protoGravatar Googler2016-09-21
| | | | | | | RELNOTES: Remove deprecated absolute paths in blaze IDE artifacts -- MOS_MIGRATED_REVID=133758389
* Implement label visitation using visitorGravatar Michajlo Matijkiw2016-09-21
| | | | | | | | | As opposed to building up a collection. These collections, and all their iterators, add up creating a lot of garbage. This saves us at least an ImmutableList + Iterator per label. -- MOS_MIGRATED_REVID=133754998
* Add copts attribute to swift_library.Gravatar Dmitry Shevchenko2016-09-21
| | | | | -- MOS_MIGRATED_REVID=133752908
* Rollback of commit 82d43279f93d95e4c41b4bc598a3cc05ddd1ae1a.Gravatar Laszlo Csomor2016-09-21
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | *** Reason for rollback *** Breaks TensorFlow and other Bazel jobs on ci.bazel.io *** Original change description *** Change execution root for external repositories to be ../repo Some of the important aspect of this change: * Remote repos in the execution root are under output_base/execroot/repo_name, so the prefix is ../repo_name (to escape the local workspace name). * Package roots for external repos were previously "output_base/", they are now output_base/external/repo_name (which means source artifacts always have a relative path from their repository). * Outputs are under bazel-bin/external/repo_name/ (or similarly under genfiles). Note that this is a bit of a change from how this was implemented in the previous cl. Fixes #1262. RELNOTES[INC]: Previously, an external repository would be symlinked into the execution root at execroot/local_repo/external/remote_repo. This changes it to be at execroot/remote_repo. This may break genrules/Skylark actions that hardcode execution root paths. If this causes breakages for you, ensure that genrules are using $(location :target) to access files and Skylark rules are using http://bazel.io/docs/skylark/lib/File.html's path, dirname, etc. functions. Roll forward of bdfd58a. -- MOS_MIGRATED_REVID=133709658
* Expose processor classpath and classnames to Skylark.Gravatar Dmitry Lomov2016-09-21
| | | | | -- MOS_MIGRATED_REVID=133704700
* Basic implementation of a remote gRPC based cache.Gravatar Ola Rozenfeld2016-09-21
| | | | | | | TODO during review: add A LOT more tests! -- MOS_MIGRATED_REVID=133702188