アノテーションインターフェース ShellTest
@TargetSE(TYPESE)
@RetentionSE(RUNTIMESE)
@DocumentedSE
@InheritedSE
@BootstrapWith(ShellTestContextBootstrapper.class)
@ExtendWith(org.springframework.test.context.junit.jupiter.SpringExtension.class)
@OverrideAutoConfiguration(enabled=false)
@TypeExcludeFilters(ShellTypeExcludeFilter.class)
@AutoConfigureShell
@AutoConfigureShellTestClient
@ImportAutoConfiguration
public @interface ShellTest
シェルコンポーネントのみに焦点を当てたシェルテストに使用できるアノテーション。
オプション要素の概要
オプション要素修飾子と型オプションの要素説明ClassSE<?>[]このテストに適用する必要がある自動構成の除外。org.springframework.context.annotation.ComponentScan.Filter[]それ以外の場合はアプリケーションコンテキストに追加される Bean のフィルタリングに使用できる除外フィルターのセット。org.springframework.context.annotation.ComponentScan.Filter[]他の方法でフィルタリングされた Bean をアプリケーションコンテキストに追加するために使用できる一連の組み込みフィルター。StringSE[]テストを実行する前に SpringEnvironmentに追加する必要がある key = value 形式のプロパティ。intエミュレートされたターミナルの高さを設定します。intエミュレートされたターミナルの幅を設定します。booleanデフォルトのフィルタリングを@SpringBootApplicationで使用するかどうかを決定します。
要素の詳細
properties
StringSE[] propertiesテストを実行する前に SpringEnvironmentに追加する必要がある key = value 形式のプロパティ。- 戻り値:
- 追加するプロパティ
- デフォルト:
- {}
terminalWidth
@PropertyMapping(value="spring.shell.test.terminal-width", skip=ON_DEFAULT_VALUE) int terminalWidthエミュレートされたターミナルの幅を設定します。- 戻り値:
- エミュレートされたターミナルの幅
- デフォルト:
- 80
terminalHeight
@PropertyMapping(value="spring.shell.test.terminal-height", skip=ON_DEFAULT_VALUE) int terminalHeightエミュレートされたターミナルの高さを設定します。- 戻り値:
- エミュレートされたターミナルの高さ
- デフォルト:
- 24
useDefaultFilters
boolean useDefaultFiltersデフォルトのフィルタリングを@SpringBootApplicationで使用するかどうかを決定します。- 戻り値:
- デフォルトのフィルターを使用する必要がある場合
- 関連事項:
- デフォルト:
- true
includeFilters
org.springframework.context.annotation.ComponentScan.Filter[] includeFilters他の方法でフィルタリングされた Bean をアプリケーションコンテキストに追加するために使用できる一連の組み込みフィルター。- 戻り値:
- 適用するフィルターを含める
- デフォルト:
- {}
excludeFilters
org.springframework.context.annotation.ComponentScan.Filter[] excludeFiltersそれ以外の場合はアプリケーションコンテキストに追加される Bean のフィルタリングに使用できる除外フィルターのセット。- 戻り値:
- 適用するフィルターを除外する
- デフォルト:
- {}
excludeAutoConfiguration
@AliasFor(annotation=org.springframework.boot.autoconfigure.ImportAutoConfiguration.class, attribute="exclude") ClassSE<?>[] excludeAutoConfigurationこのテストに適用する必要がある自動構成の除外。- 戻り値:
- 適用する自動構成除外
- デフォルト:
- {}