Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
G
Googletest
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Requirements
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Locked files
Build
Pipelines
Jobs
Pipeline schedules
Test cases
Artifacts
Deploy
Releases
Package registry
Container Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Code review analytics
Issue analytics
Insights
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to JiHu GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Meng
Googletest
Commits
b2521c89
Commit
b2521c89
authored
8 years ago
by
danilcha
Committed by
GitHub
8 years ago
Browse files
Options
Downloads
Patches
Plain Diff
Update README.md
parent
aa148eb2
No related branches found
Branches containing commit
No related tags found
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
googlemock/README.md
+24
-3
24 additions, 3 deletions
googlemock/README.md
with
24 additions
and
3 deletions
googlemock/README.md
+
24
−
3
View file @
b2521c89
...
...
@@ -125,13 +125,34 @@ build Google Mock and its tests, which has further requirements:
### Building Google Mock ###
#### Using CMake ####
If you have CMake available, it is recommended that you follow the
[
build instructions
][
gtest_cmakebuild
]
as described for Google Test. If are using Google Mock with an
as described for Google Test.
If are using Google Mock with an
existing CMake project, the section
[
Incorporating Into An Existing CMake Project
][
gtest_incorpcmake
]
may be of particular interest. Otherwise, the following sections
detail how to build Google Mock without CMake.
may be of particular interest.
The only modification you will need is to change
target_link_libraries(example gtest_main)
to
target_link_libraries(example gmock_main)
However, we also recommend adding the following lines (if using CMake 2.8.11 or later):
target_include_directories(gtest SYSTEM INTERFACE "${gtest_SOURCE_DIR}/include")
target_include_directories(gtest_main SYSTEM INTERFACE "${gtest_SOURCE_DIR}/include")
target_include_directories(gmock SYSTEM INTERFACE "${gmock_SOURCE_DIR}/include")
target_include_directories(gmock_main SYSTEM INTERFACE "${gmock_SOURCE_DIR}/include")
This marks Google Mock includes as system, which will silence compiler warnings when
compiling your tests using clang with
`-Wpedantic -Wall -Wextra -Wconversion`
.
#### Preparing to Build (Unix only) ####
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment