Debian Codegraph @

junit-jupiter-api/src/main/java/org/junit/jupiter/api/condition/EnabledIfCondition.java

raw symbols SCIP
1 /*
2 * Copyright 2015-2024 the original author or authors.
3 *
4 * All rights reserved. This program and the accompanying materials are
5 * made available under the terms of the Eclipse Public License v2.0 which
6 * accompanies this distribution and is available at
7 *
8 * https://www.eclipse.org/legal/epl-v20.html
9 */
10
11 package org.junit.jupiter.api.condition;
12
13 import org.junit.jupiter.api.extension.ExecutionCondition;
14
15 /**
16 * {@link ExecutionCondition} for {@link EnabledIf @EnabledIf}.
17 *
18 * @since 5.7
19 * @see EnabledIf
20 */
21 class EnabledIfCondition extends MethodBasedCondition<EnabledIf> {
22
23 EnabledIfCondition() {
24 super(EnabledIf.class, EnabledIf::value, EnabledIf::disabledReason);
25 }
26
27 @Override
28 protected boolean isEnabled(boolean methodResult) {
29 return methodResult;
30 }
31
32 }