Lines Matching +full:build +full:- +full:in
4 build system. If you're using GoogleTest for the first time or need a refresher,
13 * [Bazel](https://bazel.build/), the preferred build system used by the
20 [Bazel installation guide](https://bazel.build/install).
22 {: .callout .note} Note: The terminal commands in this tutorial show a Unix
28 [Bazel workspace](https://docs.bazel.build/versions/main/build-ref.html#workspace)
30 software you want to build. Each workspace directory has a text file named
32 dependencies required to build the outputs.
42 [Bazel external dependency](https://docs.bazel.build/versions/main/external.html)
44 [`http_archive` rule](https://docs.bazel.build/versions/main/repo/http.html#http_archive).
45 To do this, in the root directory of your workspace (`my_workspace/`), create a
54 strip_prefix = "googletest-5ab508a01f9eb089207ee87fd547d290da39d015",
59 as a ZIP archive from GitHub. In the above example,
64 Now you're ready to build C++ code that uses GoogleTest.
71 As an example, create a file named `hello_test.cc` in your `my_workspace`
90 To build the code, create a file named `BUILD` in the same directory with the
102 This `cc_test` rule declares the C++ test binary you want to build, and links to
103 GoogleTest (`//:gtest_main`) using the prefix you specified in the `WORKSPACE`
104 file (`@com_google_googletest`). For more information about Bazel `BUILD` files,
106 [Bazel C++ Tutorial](https://docs.bazel.build/versions/main/tutorial/cpp.html).
109 NOTE: In the example below, we assume Clang or GCC and set `--cxxopt=-std=c++14`
112 `--cxxopt=/std:c++14`. See [Supported Platforms](platforms.md) for more details
115 Now you can build and run your test:
118 <strong>my_workspace$ bazel test --cxxopt=-std=c++14 --test_output=all //:hello_test</strong>
125 [----------] Global test environment set-up.
126 [----------] 1 test from HelloTest
129 [----------] 1 test from HelloTest (0 ms total)
131 [----------] Global test environment tear-down
135 Target //:hello_test up-to-date:
136 bazel-bin/hello_test
138 INFO: 27 processes: 8 internal, 19 linux-sandbox.
139 INFO: Build completed successfully, 27 total actions
140 //:hello_test PASSED in 0.1s
142 INFO: Build completed successfully, 27 total actions