MCPcopy Index your code
hub / github.com/google/truth

github.com/google/truth @v1.4.5

Chat with this repo
repository ↗ · DeepWiki ↗ · release v1.4.5 ↗ · + Follow
4,189 symbols 23,028 edges 185 files 1,032 documented · 25% 13 cross-repo links
What it actually does AI analysis from the code graph — generated when you open this
loading…
README

Main Site Build Status Maven Release Stackoverflow

What is Truth?

Truth makes your test assertions and failure messages more readable. Similar to AssertJ, it natively supports many JDK and Guava types, and it is extensible to others.

Truth is owned and maintained by the Guava team. It is used in the majority of the tests in Google’s own codebase.

Read more at the main website.

Extension points exported contracts — how you extend this code

BinaryPredicate (Interface)
A functional interface for a binary predicate, to be used to test whether a pair of objects of types A and {@cod [5 implementers]
core/src/main/java/com/google/common/truth/Correspondence.java
IterableOfProtosUsingCorrespondence (Interface)
Comparison methods, which enforce the rules set in prior calls to IterableOfProtosFluentAssertion. [3 implementers]
extensions/proto/src/main/java/com/google/common/truth/extensions/proto/IterableOfProtosUsingCorrespondence.java
DiffFormatter (Interface)
A functional interface to be used format the diff between a pair of objects of types A and E. This i [4 implementers]
core/src/main/java/com/google/common/truth/Correspondence.java
MultimapWithProtoValuesFluentAssertion (Interface)
Fluent API to perform detailed, customizable comparison of Multimaps containing protocol buffers as values. The [2 implementers]
extensions/proto/src/main/java/com/google/common/truth/extensions/proto/MultimapWithProtoValuesFluentAssertion.java
FailureStrategy (Interface)
Defines what to do when a check fails. This type does not appear directly in a fluent assertion chain, but you choos [4 …
core/src/main/java/com/google/common/truth/FailureStrategy.java
MapWithProtoValuesFluentAssertion (Interface)
Fluent API to perform detailed, customizable comparison of maps containing protocol buffers as values. The same comparis [2 …
extensions/proto/src/main/java/com/google/common/truth/extensions/proto/MapWithProtoValuesFluentAssertion.java
Ordered (Interface)
Returned by calls like IterableSubject#containsExactly, Ordered lets the caller additionally check that [4 implementers]
core/src/main/java/com/google/common/truth/Ordered.java
ProtoFluentAssertion (Interface)
Fluent API to perform detailed, customizable comparison of Protocol buffers. Methods may be chained in any order, bu [1 …
extensions/proto/src/main/java/com/google/common/truth/extensions/proto/ProtoFluentAssertion.java

Core symbols most depended-on inside this repo

Shape

Method 3,864
Class 281
Interface 30
Enum 14

Languages

Java100%

Modules by API surface

core/src/test/java/com/google/common/truth/IterableSubjectTest.java187 symbols
core/src/test/java/com/google/common/truth/MapSubjectTest.java161 symbols
core/src/test/java/com/google/common/truth/MultimapSubjectTest.java142 symbols
core/src/test/java/com/google/common/truth/SubjectTest.java109 symbols
core/src/test/java/com/google/common/truth/IterableSubjectCorrespondenceTest.java106 symbols
extensions/proto/src/main/java/com/google/common/truth/extensions/proto/DiffResult.java105 symbols
core/src/main/java/com/google/common/truth/ActualValueInference.java97 symbols
core/src/main/java/com/google/common/truth/IterableSubject.java94 symbols
core/src/test/java/com/google/common/truth/StringSubjectTest.java83 symbols
extensions/proto/src/main/java/com/google/common/truth/extensions/proto/IterableOfProtosSubject.java82 symbols
core/src/main/java/com/google/common/truth/Subject.java72 symbols
extensions/proto/src/main/java/com/google/common/truth/extensions/proto/FieldScopeLogic.java69 symbols

For agents

$ claude mcp add truth \
  -- python -m otcore.mcp_server <graph>

⬇ download graph artifact

Ask about this repo answers extend the page