| Package | Description |
|---|---|
| org.assertj.core.api |
| Modifier and Type | Class and Description |
|---|---|
class |
AbstractStringAssert<SELF extends AbstractStringAssert<SELF>> |
| Modifier and Type | Class and Description |
|---|---|
class |
StringAssert
Assertion methods for
Strings. |
| Modifier and Type | Field and Description |
|---|---|
static InstanceOfAssertFactory<String,AbstractStringAssert<?>> |
InstanceOfAssertFactories.STRING
InstanceOfAssertFactory for a String. |
| Modifier and Type | Method and Description |
|---|---|
AbstractStringAssert<?> |
AbstractByteArrayAssert.asBase64Encoded()
Encodes the actual array into a Base64 string, the encoded string becoming the new object under test.
|
AbstractStringAssert<?> |
AbstractByteArrayAssert.asHexString()
Converts the actual byte array under test to an hexadecimal String and returns assertions for the computed String
allowing String specific assertions from this call.
|
default AbstractStringAssert<?> |
WithAssertions.assertThat(String actual)
Creates a new instance of
. |
static AbstractStringAssert<?> |
Java6Assertions.assertThat(String actual)
Deprecated.
Creates a new instance of
. |
static AbstractStringAssert<?> |
AssertionsForClassTypes.assertThat(String actual)
Creates a new instance of
. |
static AbstractStringAssert<?> |
Assertions.assertThat(String actual)
Creates a new instance of
. |
AbstractStringAssert<?> |
AbstractByteArrayAssert.asString()
Converts the actual byte[] under test to a String and returns assertions for the computed String
allowing String specific assertions from this call.
|
AbstractStringAssert<?> |
AbstractAssert.asString()
Returns a String assertion for the
toString() of the actual
value, to allow chaining of String-specific assertions from this call. |
AbstractStringAssert<?> |
AbstractInputStreamAssert.asString(Charset charset)
Converts the content of the actual
InputStream to a String by decoding its bytes using the given charset
and returns assertions for the computed String allowing String specific assertions from this call. |
AbstractStringAssert<?> |
AbstractByteArrayAssert.asString(Charset charset)
Converts the actual byte[] under test to a String by decoding the specified bytes using the given charset
and returns assertions for the computed String
allowing String specific assertions from this call.
|
default AbstractStringAssert<?> |
WithAssumptions.assumeThat(String actual)
Creates a new instance of
assumption. |
static AbstractStringAssert<?> |
Assumptions.assumeThat(String actual)
Creates a new instance of
assumption. |
AbstractStringAssert<?> |
AbstractPathAssert.content()
Returns String assertions on the content of the actual
Path read with the default charset. |
AbstractStringAssert<?> |
AbstractFileAssert.content()
Returns String assertions on the content of the actual
File read with the default charset. |
AbstractStringAssert<?> |
AbstractPathAssert.content(Charset charset)
Returns String assertions on the content of the actual
Path read with the given Charset. |
AbstractStringAssert<?> |
AbstractFileAssert.content(Charset charset)
Returns String assertions on the content of the actual
File read with the given Charset. |
AbstractStringAssert<?> |
AbstractByteArrayAssert.encodedAsBase64()
Deprecated.
use
AbstractByteArrayAssert.asBase64Encoded() instead.
Encodes the actual array into a Base64 string, the encoded string becoming the new object under test. Examples: |
static AbstractStringAssert<?> |
BDDAssumptions.given(String actual)
Creates a new assumption's instance for a
String value. |
AbstractStringAssert<?> |
AbstractThrowableAssert.message()
A shortcut for
extracting(Throwable::getMessage, as(InstanceOfAssertFactories.STRING)) which allows
to extract a throwable's message and then execute assertions on it. |
static AbstractStringAssert<?> |
Java6BDDAssertions.then(String actual)
Deprecated.
Creates a new instance of
. |
static AbstractStringAssert<?> |
BDDAssertions.then(String actual)
Creates a new instance of
. |
Copyright © 2025. All rights reserved.