Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
G
googletest
Project
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Chen Yisong
googletest
Commits
5cfc63dd
Commit
5cfc63dd
authored
May 06, 2021
by
Abseil Team
Committed by
CJ Johnson
May 13, 2021
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Googletest export
Fix links in Matchers Reference PiperOrigin-RevId: 372436732
parent
df157130
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
3 additions
and
3 deletions
+3
-3
matchers.md
docs/reference/matchers.md
+3
-3
No files found.
docs/reference/matchers.md
View file @
5cfc63dd
...
@@ -55,7 +55,7 @@ will be changed.
...
@@ -55,7 +55,7 @@ will be changed.
`IsTrue`
and
`IsFalse`
are useful when you need to use a matcher, or for types
`IsTrue`
and
`IsFalse`
are useful when you need to use a matcher, or for types
that can be explicitly converted to Boolean, but are not implicitly converted to
that can be explicitly converted to Boolean, but are not implicitly converted to
Boolean. In other cases, you can use the basic
Boolean. In other cases, you can use the basic
[
`EXPECT_TRUE` and `EXPECT_FALSE`
](
primer.md#basic-assertions
)
assertions.
[
`EXPECT_TRUE` and `EXPECT_FALSE`
](
../
primer.md#basic-assertions
)
assertions.
### Floating-Point Matchers {#FpMatchers}
### Floating-Point Matchers {#FpMatchers}
...
@@ -100,7 +100,7 @@ The `argument` can be either a C string or a C++ string object:
...
@@ -100,7 +100,7 @@ The `argument` can be either a C string or a C++ string object:
`ContainsRegex()`
and
`MatchesRegex()`
take ownership of the
`RE`
object. They
`ContainsRegex()`
and
`MatchesRegex()`
take ownership of the
`RE`
object. They
use the regular expression syntax defined
use the regular expression syntax defined
[
here
](
advanced.md#regular-expression-syntax
)
. All of these matchers, except
[
here
](
../
advanced.md#regular-expression-syntax
)
. All of these matchers, except
`ContainsRegex()`
and
`MatchesRegex()`
work for wide strings as well.
`ContainsRegex()`
and
`MatchesRegex()`
work for wide strings as well.
### Container Matchers
### Container Matchers
...
@@ -242,7 +242,7 @@ You can make a matcher from one or more other matchers:
...
@@ -242,7 +242,7 @@ You can make a matcher from one or more other matchers:
| Matcher | Description |
| Matcher | Description |
| :---------------------- | :------------------------------------ |
| :---------------------- | :------------------------------------ |
|
`MatcherCast<T>(m)`
| casts matcher
`m`
to type
`Matcher<T>`
. |
|
`MatcherCast<T>(m)`
| casts matcher
`m`
to type
`Matcher<T>`
. |
|
`SafeMatcherCast<T>(m)`
|
[
safely casts
](
gmock_cook_book.md#casting-matchers
)
matcher
`m`
to type
`Matcher<T>`
. |
|
`SafeMatcherCast<T>(m)`
|
[
safely casts
](
../gmock_cook_book.md#SafeMatcherCast
)
matcher
`m`
to type
`Matcher<T>`
. |
|
`Truly(predicate)`
|
`predicate(argument)`
returns something considered by C++ to be true, where
`predicate`
is a function or functor. |
|
`Truly(predicate)`
|
`predicate(argument)`
returns something considered by C++ to be true, where
`predicate`
is a function or functor. |
`AddressSatisfies(callback)`
and
`Truly(callback)`
take ownership of
`callback`
,
`AddressSatisfies(callback)`
and
`Truly(callback)`
take ownership of
`callback`
,
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment