commit | 469d855ed68f6f2e79a0d45bb517471be8c380a4 | [log] [tgz] |
---|---|---|
author | adonovan <adonovan@google.com> | Tue Feb 11 09:07:25 2020 -0800 |
committer | Copybara-Service <copybara-worker@google.com> | Tue Feb 11 09:08:49 2020 -0800 |
tree | 6ac9db024ff4ddf336f9a517c875a213fcd8f388 | |
parent | 59d7864b3a39008e6b4d1447abcdc59cd9906e88 [diff] |
bazel tests: delete TestMode and other test junk The only differences in the test modes, BUILD and SKYLARK, were: - the name of the Mutability, which is insignificant. - whether "BUILD dialect checks", such as no def, no f(**kwargs), are applied. These are moved from syntax.EvaluationTest to packages.PackageFactoryTest. - whether validation errors were reported as events or a thrown exception. Now it's always an exception. - whether the validator gets the 'isBuildFile' flag. This affects a small (and diminishing) set of things, which should be checked directly. The ModalTestCase hierarchy (base, BUILD only, Skylark only, both modes) has been flattened into a single class, Scenario. EvaluationTestCase: - newStarlarkThreadWithSkylarkOptions is now setSemantics (stateful) - inline the code formerly in TestMode and simplify newStarlarkThread et al. - make bad dependencies on build-base explicit. (They are revealed, but not new.) - hide fields - simplify exec(). SkylarkEvaluationTest: - break "extends EvaluationTest" edge: There's no need to duplicate the whole suite for both modes; nearly every test was independent of mode (and one suspects most were added with no knowledge of the intended design). - move tests of FlagGuardedValue into StarlarkFlagGuardingTest. (They were the only tests to use the 'builtins' parameter, now removed.) PiperOrigin-RevId: 294451364
{Fast, Correct} - Choose two
Build and test software of any size, quickly and reliably.
Speed up your builds and tests: Bazel rebuilds only what is necessary. With advanced local and distributed caching, optimized dependency analysis and parallel execution, you get fast and incremental builds.
One tool, multiple languages: Build and test Java, C++, Android, iOS, Go, and a wide variety of other language platforms. Bazel runs on Windows, macOS, and Linux.
Scalable: Bazel helps you scale your organization, codebase, and continuous integration solution. It handles codebases of any size, in multiple repositories or a huge monorepo.
Extensible to your needs: Easily add support for new languages and platforms with Bazel's familiar extension language. Share and re-use language rules written by the growing Bazel community.
Follow our tutorials:
See CONTRIBUTING.md