Interface MocksConfig

All Known Implementing Classes:
MocksApi

public interface MocksConfig
Interface that defines helper configuration methods for helper operations. Validates that all required methods are implemented.
  • Method Summary

    Modifier and Type
    Method
    Description
    Returns and logs (at INFO level) a human-readable summary of all resolved configuration values.
    setAwaitMs(int awaitMs)
    Configure global await for asserts with await
    setEnchantedReport(boolean enchantedReport)
    Enabling or disabling enchanted mockVerify report
    setLogging(boolean enable)
    Enables or disables logging manually (debug log level will print logs anyway!)
    withAwaitMs(int awaitMs)
    Configure await for next assert with await (than await rollback to global) global setAwaitMs(int) will be ignored
  • Method Details

    • setAwaitMs

      MocksApi setAwaitMs(int awaitMs)
      Configure global await for asserts with await
      Parameters:
      awaitMs - await ms
      Returns:
      this instance for method chaining
      Throws:
      IllegalArgumentException - on invalid setup
    • withAwaitMs

      MocksApi withAwaitMs(int awaitMs)
      Configure await for next assert with await (than await rollback to global) global setAwaitMs(int) will be ignored
      Parameters:
      awaitMs - ms await
      Returns:
      this instance for method chaining
      Throws:
      IllegalArgumentException - on invalid setup
    • setLogging

      MocksApi setLogging(boolean enable)
      Enables or disables logging manually (debug log level will print logs anyway!)
      Parameters:
      enable - true=request/response logging (Allure on always!)
      Returns:
      this instance for method chaining
    • setEnchantedReport

      MocksApi setEnchantedReport(boolean enchantedReport)
      Enabling or disabling enchanted mockVerify report

      Same behavior as MockEnchantedDiffer.

      Parameters:
      enchantedReport - true=on/false=off
      Returns:
      this instance for method chaining
    • getConfigSummary

      String getConfigSummary()
      Returns and logs (at INFO level) a human-readable summary of all resolved configuration values.

      The summary includes values loaded from the YAML configuration file as well as any fields overridden programmatically after construction. Optional fields that were not present in the configuration and resolved via default values may also be included.

      Returns:
      String with summary