Interface PactLoader
public interface PactLoader
Encapsulate logic for loading pacts
-
Method Summary
Modifier and TypeMethodDescriptiondefault StringReturns a description of this pact loaderdefault voidenablePendingPacts(boolean flag) Enables pending pact featureau.com.dius.pact.core.model.PactSourceReturns the source object that the pacts where loaded fromdefault voidinitLoader(Class<?> testClass, Object testInstance) Supports additional initialisation using the test classList<au.com.dius.pact.core.model.Pact>Load pacts from appropriate sourcedefault voidsetValueResolver(au.com.dius.pact.core.support.expressions.ValueResolver valueResolver) Sets the value resolver to use to resolve property expressions.
-
Method Details
-
load
Load pacts from appropriate source- Parameters:
providerName- name of provider for which pacts will be loaded- Returns:
- list of pacts
- Throws:
IOException
-
getPactSource
au.com.dius.pact.core.model.PactSource getPactSource()Returns the source object that the pacts where loaded from -
setValueResolver
default void setValueResolver(au.com.dius.pact.core.support.expressions.ValueResolver valueResolver) Sets the value resolver to use to resolve property expressions. By default, a system property resolver will be used.- Parameters:
valueResolver- Value Resolver
-
description
Returns a description of this pact loader -
enablePendingPacts
default void enablePendingPacts(boolean flag) Enables pending pact feature -
initLoader
Supports additional initialisation using the test class
-