NamespaceBlockedException extends DittoRuntimeException { public static DittoRuntimeExceptionBuilder<NamespaceBlockedException> newBuilder(final String namespace) { return new Builder() .message(MessageFormat.format(MESSAGE_TEMPLATE, namespace)) .description(DEFAULT_DESCRIPTION); } private  NamespaceBlockedException(final DittoHeaders dittoHeaders,
            @Nullable final String message,
            @Nullable final String description,
            @Nullable final Throwable cause,
            @Nullable final URI href); static DittoRuntimeExceptionBuilder<NamespaceBlockedException> newBuilder(final String namespace); static NamespaceBlockedException fromJson(final JsonObject jsonObject, final DittoHeaders dittoHeaders); DittoRuntimeExceptionBuilder<NamespaceBlockedException> toBuilder(); static final String ERROR_CODE; }
@Test public void copy() { final NamespaceBlockedException underTest = NamespaceBlockedException.newBuilder("ns").build(); final DittoRuntimeException copy = DittoRuntimeException.newBuilder(underTest).build(); assertThat(copy.getMessage()).isEqualTo(underTest.getMessage()); assertThat(copy.getDescription()).isEqualTo(underTest.getDescription()); assertThat(copy.getHref()).isEqualTo(underTest.getHref()); assertThat(copy.getDittoHeaders()).isEqualTo(underTest.getDittoHeaders()); }