Class ServerControlAssert
java.lang.Object
org.assertj.core.api.AbstractAssert<ServerControlAssert,@Nullable IServerControl>
nl.pim16aap2.lightkeeper.framework.assertions.ServerControlAssert
- All Implemented Interfaces:
org.assertj.core.api.Assert<ServerControlAssert,,IServerControl> org.assertj.core.api.Descriptable<ServerControlAssert>,org.assertj.core.api.ExtensionPoints<ServerControlAssert,IServerControl>
public final class ServerControlAssert
extends org.assertj.core.api.AbstractAssert<ServerControlAssert,@Nullable IServerControl>
Eager assertions over live server observations.
Each assertion reads current state. Use LightkeeperAssertions.eventually(java.time.Duration, nl.pim16aap2.lightkeeper.framework.assertions.LightkeeperAssertions.RetryingAssertion) for explicit retries.
-
Field Summary
Fields inherited from class org.assertj.core.api.AbstractAssert
info, throwUnsupportedExceptionOnEquals -
Method Summary
Modifier and TypeMethodDescriptionerrors()Asserts that no error-severity server entries have been captured.hasNoErrors(Predicate<ServerErrorSnapshot> allowedErrors) Asserts that no error-severity entries remain after applying an allowlist.isPaper()Asserts that the server runs on Paper.isSpigot()Asserts that the server runs on Spigot.org.assertj.core.api.ListAssert<String> output()Returns ordinary list assertions over the output captured at this navigation call.Selects a plugin for live presence, enabled-state, and version assertions without querying the server yet.Methods inherited from class org.assertj.core.api.AbstractAssert
actual, asInstanceOf, asList, asString, describedAs, descriptionText, doesNotHave, doesNotHaveSameClassAs, doesNotHaveSameHashCodeAs, doesNotHaveToString, doesNotHaveToString, doesNotMatch, doesNotMatch, equals, getWritableAssertionInfo, has, hashCode, hasSameClassAs, hasSameHashCodeAs, hasToString, hasToString, is, isEqualTo, isExactlyInstanceOf, isIn, isIn, isInstanceOf, isInstanceOfAny, isInstanceOfSatisfying, isNot, isNotEqualTo, isNotExactlyInstanceOf, isNotIn, isNotIn, isNotInstanceOf, isNotInstanceOfAny, isNotNull, isNotOfAnyClassIn, isNotSameAs, isNull, isOfAnyClassIn, isSameAs, matches, matches, overridingErrorMessage, overridingErrorMessage, satisfies, satisfies, satisfies, satisfiesAnyOf, satisfiesAnyOf, setCustomRepresentation, setDescriptionConsumer, setPrintAssertionsDescription, usingComparator, usingComparator, usingDefaultComparator, usingEquals, usingEquals, withFailMessage, withFailMessage, withRepresentation, withThreadDumpOnErrorMethods inherited from class java.lang.Object
getClass, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface org.assertj.core.api.Descriptable
as, as, as, describedAs, describedAs
-
Method Details
-
errors
- Returns:
- Live structured error/warning assertions, without consuming or clearing entries.
-
plugin
Selects a plugin for live presence, enabled-state, and version assertions without querying the server yet.- Parameters:
pluginName- Plugin name from itsplugin.yml; must not be blank.- Returns:
- Plugin assertions that re-query the named plugin on each evaluation.
-
isPaper
Asserts that the server runs on Paper.- Returns:
- This assertion for fluent chaining.
-
isSpigot
Asserts that the server runs on Spigot.- Returns:
- This assertion for fluent chaining.
-
output
Returns ordinary list assertions over the output captured at this navigation call.Recreate this navigation inside an
eventuallycallback to observe new output.- Returns:
- Assertions over the captured output lines.
-
hasNoErrors
Asserts that no error-severity server entries have been captured. Warnings are ignored.- Returns:
- This assertion for fluent chaining.
-
hasNoErrors
Asserts that no error-severity entries remain after applying an allowlist.- Parameters:
allowedErrors- Predicate matching known-benign captured errors to ignore.- Returns:
- This assertion for fluent chaining.
-