arquillian-algeron's People
arquillian-algeron's Issues
Update documentation before release of alpha2
Update documentation with:
- new HttpTarget method to simplify everything.
Make default target location of contracts smart of building tool
Issue Overview
Make default target location of contracts smart of building tool. Currently always the contracts are stored to target/pacts
(in case of Pact).
Expected Behaviour
In case of using Gradle report output could be build/reports/pact
Current Behaviour
Always target/pacts
Add PactStorage in consumer
Create a similar concept as @PactLoader
but called @PactStorage
to be used in Consumer side to upload pacts.
Currently Producer part uses @PactLoader
to get contracts from different sources.
To publish the contracts currently there is no annotation and it just relies on build tool to publish contracts.
The idea is to implement something similar as https://github.com/arquillian/arquillian-pact/tree/master/provider/spi/src/main/java/org/arquillian/pact/provider/spi/loader but called PactStorage
instead of PactLoader
.
The default implementations that must offer is @PactFolder
which moves contracts from generated folder (can be the default one or the one set as system property pact.verification.reportDir
).
Also in different module like happens in provider (https://github.com/arquillian/arquillian-pact/tree/master/provider) should be supported @PactGit
and @PactBroker.
PactBroker
example can be taken from https://github.com/DiUS/pact-jvm/tree/master/pact-jvm-provider-gradle/src/main/groovy/au/com/dius/pact/provider/gradle
Create integration between Pact Provider and Arquillian Recorder
Currently pact generates report from contract tests in several formats, including MD or JSON. Create our own report as Arquillian Reporter extension.
Make PactVerification value not mandatory
Issue Overview
When you want to write a consumer test method you need to specify that the method tests a consumer contract by using @PactVerification
annotation and setting which provider you are verifying.
In case of using @Pact
annotation at class level, this information is redundant (the value of the annotation) so it could be retrieved from there instead of forcing users to set it again.
Expected Behaviour
@RunWith(Arquillian.class)
@Pact(provider="test_provider", consumer="test_consumer")
public class ClientGatewayTest {
@Deployment
public static JavaArchive createDeployment() {
return ShrinkWrap.create(JavaArchive.class).addClasses(ClientGateway.class);
}
public PactFragment createFragment(PactDslWithProvider builder) {
Map<String, String> header = new HashMap<>();
header.put("Content-Type", "application/json");
Map<String, Object> stateParams = new HashMap<>();
stateParams.put("name", "Alexandra");
return builder
.given("test state", stateParams)
.uponReceiving("ConsumerTest test interaction")
.path("/")
.method("GET")
.willRespondWith()
.status(200)
.headers(header)
.body("{\"responsetest\": true, \"name\": \"harry\"}")
.toFragment();
}
@EJB
ClientGateway clientGateway;
@Test
@PactVerification
public void should_return_message() throws IOException {
assertThat(clientGateway.getMessage(), is("{\"responsetest\": true, \"name\": \"harry\"}"));
}
}
Current Behaviour
@RunWith(Arquillian.class)
@Pact(provider="test_provider", consumer="test_consumer")
public class ClientGatewayTest {
@Deployment
public static JavaArchive createDeployment() {
return ShrinkWrap.create(JavaArchive.class).addClasses(ClientGateway.class);
}
public PactFragment createFragment(PactDslWithProvider builder) {
Map<String, String> header = new HashMap<>();
header.put("Content-Type", "application/json");
Map<String, Object> stateParams = new HashMap<>();
stateParams.put("name", "Alexandra");
return builder
.given("test state", stateParams)
.uponReceiving("ConsumerTest test interaction")
.path("/")
.method("GET")
.willRespondWith()
.status(200)
.headers(header)
.body("{\"responsetest\": true, \"name\": \"harry\"}")
.toFragment();
}
@EJB
ClientGateway clientGateway;
@Test
@PactVerification("test_provider")
public void should_return_message() throws IOException {
assertThat(clientGateway.getMessage(), is("{\"responsetest\": true, \"name\": \"harry\"}"));
}
}
Simplify setting Consumer/Provider in consumer part
Simplify set Consumer/Provider in consumer part. Currently we need to use @Pact
annotation and set the consumer and the provider. The problem is that if you use pact fragments (and probably you are doing to maintain the unit of tests clear), you need to set these attributes over and over again. Change @Pact
annotation to be able to set at class level.
This has some implications in current code:
- Instead of getting all methods annotated with
@Pact
, need to get all methods that returns a class thatisAssignableFrom
the classPactFragment
. - For all methods that returns
PactFragment
need to check if they are annotated with@Pact
. If they are annotated, the consumer and provider set there are used. If not get the@Pact
information from class level. - If no
@Pact
is provided at method or class level, an exception is thrown.
It is important to note that @Pact
annotation can be in current test class or in a subclass. The algorithm to check this can be taken from https://github.com/lordofthejars/nosql-unit/blob/master/nosqlunit-core/src/main/java/com/lordofthejars/nosqlunit/core/IOUtils.java#L35
This code must be implemented at method https://github.com/arquillian/arquillian-pact/blob/master/consumer/core/src/main/java/org/arquillian/pact/consumer/core/AbstractConsumerPactTest.java#L102
To improve the performance we can think about a caching system to not having to find all @Pact
annotations in all test executions.
Simplify target call
Simplify target call by only receiving URL and getting consumer, interactions, ... from context
Add resolution of ~ symbol in folder publisher and retriever.
Add resolution of ~
symbol in folder publisher and retriever to home directory.
Add option to delete folder in folder publisher
Add option to delete folder in folder publisher before publishing new contracts. By default its value is false.
In GitPactLoader by default key is not correct
Change this https://github.com/arquillian/arquillian-pact/blob/master/provider/git-loader/src/main/java/org/arquillian/pact/provider/loader/git/PactGit.java#L49 to default value set in javadoc
You will need to resolve (~) to home directory.
Add integration to Consumer Groovy DSL
Add integration to Consumer Groovy DSL https://github.com/DiUS/pact-jvm/tree/master/pact-jvm-consumer-groovy so you can define the expectations in groovy file.
Probably this is already supported and it is only a documentation task.
Migrate to Pact 3.5.0 final
Migrate to Pact 3.5.0 final and change the toFragment
deprecated method to toPact
and adapt the code.
java.lang.UnsupportedOperationException: Could not find method with @Pact for the provider test_provider
at org.arquillian.algeron.pact.consumer.core.AbstractConsumerPactTest.executePactFragment(AbstractConsumerPactTest.java:57)
at org.arquillian.algeron.pact.consumer.core.AbstractConsumerPactTest.executeConsumerTest(AbstractConsumerPactTest.java:47)
at org.arquillian.algeron.pact.consumer.core.client.StandaloneConsumerPactTest.testPact(StandaloneConsumerPactTest.java:37)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:497)
at org.jboss.arquillian.core.impl.ObserverImpl.invoke(ObserverImpl.java:96)
@PactBroker doesn't work anymore
In Alpha6 an exception gets thrown when using the PactBroker annotation:
Caused by: java.lang.NoSuchMethodException: org.arquillian.algeron.pact.provider.core.loader.pactbroker.PactBrokerLoader.<init>(org.arquillian.algeron.pact.provider.core.loader.pactbroker.PactBroker)
Looking at code we find https://github.com/arquillian/arquillian-algeron/blob/master/pact/provider/core/src/main/java/org/arquillian/algeron/pact/provider/core/PactsRetriever.java#L129 as the source of the exception.
When looking at PactBrokerLoader I see that there used to be such a constructor in alpha4 but it disappeared in alpha5.
https://github.com/arquillian/arquillian-algeron/blob/1.0.0.Alpha4/provider/pact-broker-loader/src/main/java/org/arquillian/pact/provider/core/loader/pactbroker/PactBrokerLoader.java#L74
The new implementation of PactBrokerLoader certainly shows a nicer way to handle the configuration that the constructor way before. PactsRetriever hasn't been updated to that behavior so far.
@PactFolder annotation does not exist
Issue Overview
Documentation references not-existing annotation @PactFolder
Expected Behaviour
@PactFolder
should be available in the algeron project, or documentation should be updated.
Current Behaviour
See docu chapter 6.2.1. Pact Provider In Container, example references @PactFolder
annotation on as config specifying where the pacts are stored. This annotation does not exist in algeron codebase.
Add Target as ArquillianResource
Change the usage of @TestTarget
annotation by @ArquillianResource
and make it configurable from arquillian.xml
Null Pointer is thrown when using Pact at class level
Issue Overview
Null Pointer is thrown when using Pact at class level
Expected Behaviour
Get information from pact at class level
Current Behaviour
Null Pointer Exception
Persistence-Dbunit
I am running an Provider test In Client mode.
The container contains a h2 in-memory db.
I would like to change the database for each test, so i tried arquillian persistence extension, which doesnt work with In Client mode.
Do you know any solution to this problem?
Change default operator from :- to :
Issue Overview
Arquillian uses by default :
char to separate default values from system properties expressions ${myprop:defaultvalue}, the problem is that in Pact we are using :-
and this makes everything work wrong together.
Expected Behaviour
default value is used correctly
Current Behaviour
default value contains a -
minus sign.
[PACT] Allow user to define tests like Cucumber expressions
Issue Overview
Currently @States
only support state names and passing as a Map
a map of parameters.
Implement that you can pass parameters as it happens with Cucumber, something like:
-
Consumer
.states("I have 36 cukes in my belly")
.states("The following animals: cow, pig, bug")
-
Provider
@State("I have (\\d+) cukes in my belly")
public void state(int numberOfCakes){}
@State("The following animals: (.*)")
public void state(List<String> animals){}
Multiple States are executed
Issue Overview
2 States are executed before Test if one State contains name of the other State
@State("this is the first state")
public void firstState() throws URISyntaxException {
postState("this is the first state");
}
@State("this is the first state extended with something")
public void firstStateExtended() throws URISyntaxException {
postState("this is the first state extended with something");
}
Expected Behaviour
Each State should be matched on the whole String name value
Current Behaviour
Both States match before the test of "this is the first state extended with something" starts and both states will be prepared. The resulting state may fail for "this is the first state extended with something".
Additional Information
Running on Windows 10.
In GitPactLoader should use username password instead of passphrase
Update to Pact 3.5.0-beta3
Issue Overview
Update to Pact 3.5.0-beta3
Running Provider Test on Windows
Issue Overview
I created a Pact with pact-jvm-consumer-junit5_2.12.
After that i wanted to use an arquillian test to verify my provider and started with a minimal exmaple.
@RunWith(Arquillian.class)
@org.arquillian.algeron.pact.provider.spi.Provider("test_provider")
public class FirstProviderTest {
@ArquillianResource
URL baseUri;
@ArquillianResource
Target target;
@Test
public void satisfiesContracts() {
assertThat(target).withUrl(baseUri).satisfiesContract();
}
}
The folder is configured inside the arquillian.xml.
<?xml version="1.0"?>
<arquillian xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns="http://jboss.org/schema/arquillian"
xsi:schemaLocation="http://jboss.org/schema/arquillian
http://jboss.org/schema/arquillian/arquillian_1_0.xsd">
<extension qualifier="algeron-provider">
<property name="retrieverConfiguration">
provider: folder
contractsFolder: consumer-contracts
</property>
</extension>
</arquillian>
Expected Behaviour
Run provider against pact.
Fail for all tests since their are no solutions implemented.
Current Behaviour
`java.lang.IllegalArgumentException: Illegal character in authority at index 7: file://C:\projects\pact-project\test-application\target\test-classes\consumer-contracts\test_consumer-test_provider.json
at java.net.URI.create(URI.java:852)
at java.util.stream.ReferencePipeline$3$1.accept(ReferencePipeline.java:193)
at java.util.stream.ReferencePipeline$3$1.accept(ReferencePipeline.java:193)
at java.util.Spliterators$ArraySpliterator.forEachRemaining(Spliterators.java:948)
at java.util.stream.AbstractPipeline.copyInto(AbstractPipeline.java:481)
at java.util.stream.AbstractPipeline.wrapAndCopyInto(AbstractPipeline.java:471)
at java.util.stream.ReduceOps$ReduceOp.evaluateSequential(ReduceOps.java:708)
at java.util.stream.AbstractPipeline.evaluate(AbstractPipeline.java:234)
at java.util.stream.ReferencePipeline.collect(ReferencePipeline.java:499)
at org.arquillian.algeron.provider.core.retriever.ContractsFolderLoader.retrieve(ContractsFolderLoader.java:55)
at org.arquillian.algeron.pact.provider.core.PactsRetriever.getPacts(PactsRetriever.java:72)
at org.arquillian.algeron.pact.provider.core.PactsRetriever.retrievePacts(PactsRetriever.java:49)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:498)
at org.jboss.arquillian.core.impl.ObserverImpl.invoke(ObserverImpl.java:86)
at org.jboss.arquillian.core.impl.EventContextImpl.invokeObservers(EventContextImpl.java:103)
at org.jboss.arquillian.core.impl.EventContextImpl.proceed(EventContextImpl.java:90)
at org.jboss.arquillian.test.impl.TestContextHandler.createClassContext(TestContextHandler.java:83)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:498)
at org.jboss.arquillian.core.impl.ObserverImpl.invoke(ObserverImpl.java:86)
at org.jboss.arquillian.core.impl.EventContextImpl.proceed(EventContextImpl.java:95)
at org.jboss.arquillian.test.impl.TestContextHandler.createSuiteContext(TestContextHandler.java:69)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:498)
at org.jboss.arquillian.core.impl.ObserverImpl.invoke(ObserverImpl.java:86)
at org.jboss.arquillian.core.impl.EventContextImpl.proceed(EventContextImpl.java:95)
at org.jboss.arquillian.core.impl.ManagerImpl.fire(ManagerImpl.java:133)
at org.jboss.arquillian.core.impl.ManagerImpl.fire(ManagerImpl.java:105)
at org.jboss.arquillian.test.impl.EventTestRunnerAdaptor.beforeClass(EventTestRunnerAdaptor.java:80)
at org.jboss.arquillian.junit.Arquillian$2.evaluate(Arquillian.java:179)
at org.jboss.arquillian.junit.Arquillian.multiExecute(Arquillian.java:384)
at org.jboss.arquillian.junit.Arquillian.access$200(Arquillian.java:54)
at org.jboss.arquillian.junit.Arquillian$3.evaluate(Arquillian.java:193)
at org.junit.runners.ParentRunner.run(ParentRunner.java:363)
at org.jboss.arquillian.junit.Arquillian.run(Arquillian.java:148)
at org.junit.runner.JUnitCore.run(JUnitCore.java:137)
at com.intellij.junit4.JUnit4IdeaTestRunner.startRunnerWithArgs(JUnit4IdeaTestRunner.java:68)
at com.intellij.rt.execution.junit.IdeaTestRunner$Repeater.startRunnerWithArgs(IdeaTestRunner.java:47)
at com.intellij.rt.execution.junit.JUnitStarter.prepareStreamsAndStart(JUnitStarter.java:242)
at com.intellij.rt.execution.junit.JUnitStarter.main(JUnitStarter.java:70)
Caused by: java.net.URISyntaxException: Illegal character in authority at index 7: file://C:\projects\pact-project\test-application\target\test-classes\consumer-contracts\test_consumer-test_provider.json
at java.net.URI$Parser.fail(URI.java:2848)
at java.net.URI$Parser.parseAuthority(URI.java:3186)
at java.net.URI$Parser.parseHierarchical(URI.java:3097)
at java.net.URI$Parser.parse(URI.java:3053)
at java.net.URI.(URI.java:588)
at java.net.URI.create(URI.java:850)
... 46 more
Test ignored.
Disconnected from the target VM, address: '127.0.0.1:61589', transport: 'socket'
Process finished with exit code -1`
Steps To Reproduce
Additional Information
Running on Windows 10
Creates git loader
New documentation layout & update with Forge addon
Issue Overview
New documentation layout & update with Forge addon
Create an enricher which injects the URL of the http stub server
Issue Overview
Create an enricher which injects the URL of the http stub server
Expected Behaviour
@StubServer
@ArquillianResource
URL url;
Current Behaviour
Not possible to do it
Updates default pact version contract to version 3
Create Pact Broker publisher
Create integration between Pact Provider and Arquillian Reporter
Issue Overview
Currently pact generates report from contract tests in several formats, including MD or JSON. Create our own report as Arquillian Reporter extension. See example below for ideas what is already available.
Pact Publisher is not called when used with Gradle
Issue Overview
Pact Publisher is not called when used with Gradle due a bug in Gradle https://issues.gradle.org/browse/GRADLE-3411
Since Publishers reacts to AfterSuite and this event is not thrown when running in Gradle, we are going to change to AfterClass. This will has an impact on the performance but we cannot do nothing for now.
When executing Arquillian in debug mode and Gradle last events are:
(E) AfterUnDeploy
(E) StopManualContainers
(O) ContainerLifecycleController.stopManualContainers
(E) StopClassContainers
(O) ContainerLifecycleController.stopClassContainers
Expected Behaviour
Pacts are published
Current Behaviour
Pact are not published
Investigate how to add sun.net and com.sun.net packages
Currently we are adding one by one classes required by Pact from package sun.net
and com.sun.net
, cannot use ShirnkWrap
packages
method because rt.jar
was packaged without the directory entries (Full description here #76) so we need to figure out if there is a better way of doing this instead of adding one by one.
Class that needs to be improved is https://github.com/arquillian/arquillian-algeron/blob/master/pact/consumer/core/src/main/java/org/arquillian/algeron/pact/consumer/core/client/PactConsumerArchiveAppender.java
Test does not fail when contract is not verified
Issue Overview
Test does not fail when contract is not verified but only reported on console
This behaviour can be also observed in Pact-JVM
Expected Behaviour
Test fails with information on why it failed.
Current Behaviour
Test passes but console/report showing information that the contract has not been verified.
Add output directory as configuration property
Actually Pact saves by default all files into target/pacts
or the only way the user has to change it is by setting pact.rootDir
system property. Instead of forcing user to set a system property directly, we can create a configuration property that in case of being set and no property value already set in pact.rootDir
, then it should set this property and unset after everything is undeployed.
Implements provider states with parameters introduced at Version 3 of Pact Spec
Implements provider states with parameters introduced at Version 3 of Pact Spec https://github.com/pact-foundation/pact-specification/tree/version-3#allow-multiple-provider-states-with-parameters Currently in Arquillian Pact we only support the version 2 of provider states where the parameter was just a descriptive string.
States in Pact is a way of communicating from consumer part, which is the state we expect to provider side before executing the contracts tests. For example that a user must exists.
ContractsGitLoader configuration through arquillian.xml fails
Issue Overview
When I try to configure the ContractsGitLoader
through arquillian.xml instead of annotation, I get a NullPointerException because gitOperations
is not initialized.
Expected Behaviour
No NPE.
Current Behaviour
NPE occurs when getContractsFolderFromGitRepo
tries to call methods on gitOperations
.
Steps To Reproduce
- Move configuration from
@ContractsGit
annotation to arquillian.xml, remove@ContractsGit
. - Run test
Additional Information
gitOperations
is only set in the ContractsGitLoader(ContractsGit contractsGit)
constructor, but when configuring through arquillian.xml, the no-args constructor is used. The configure
method is later called to set the configuration, but this method does not initialize the gitOperations
. Probably only one line that needs to be added to configure
.
Implements TargetRequestFilter support
Implements TargetRequestFilter support https://github.com/DiUS/pact-jvm/blob/master/pact-jvm-provider-junit/src/main/java/au/com/dius/pact/provider/junit/target/HttpTarget.java#L197
Create AssertJ extension for asserting provider
Update Algeron Pact so it can be used as Service Virtualization
Issue Overview
In complex microservices architecture, usually what you have is a consumer A that calls another provider B and at the same time, this provider B acts as a consumer of other services, let's call it Providers C and D.
So when you want to validate that Consumer A meets the expectations from Provider B, you write the contract test for the consumer by stubbing Provider B. But when you want to validate that Provider B also meets the expectations you need to stub its collaborators (Providers C and D). So in this case what you need is Service Virtualization to "mock" that services.
Ideally, you should not add a new technology for service virtualization, you could use the same used on the consumer side but in provider side.
https://github.com/lordofthejars/pactstandalone
Expected Behaviour
Use Pact Consumer stubbing capabilities in Provider to simulate the service dependencies of the provider.
Update Pact version to 3.5.0-beta2
[PACT] AssertJ integration
Creates a custom matcher of AssertJ for validating contracts against provider
Latest Pact JVM introduced API changes
When bumping to 3.5.10
(as 3.5.11
has no pact_jvm
artifact available) following compilation error occurs:
[INFO] -------------------------------------------------------------
[ERROR] COMPILATION ERROR :
[INFO] -------------------------------------------------------------
[ERROR] /home/bartek/code/redhat/arquillian/arquillian-algeron/pact/provider/core/src/main/java/org/arquillian/algeron/pact/provider/core/httptarget/HttpTarget.java:[192,17] method verifyResponseFromProvider in class au.com.dius.pact.provider.ProviderVerifier cannot be applied to given types;
required: au.com.dius.pact.provider.ProviderInfo,au.com.dius.pact.model.Interaction,java.lang.String,java.util.Map,au.com.dius.pact.provider.ProviderClient
found: au.com.dius.pact.provider.ProviderInfo,au.com.dius.pact.model.RequestResponseInteraction,java.lang.String,java.util.Map<java.lang.String,java.lang.Object>
reason: actual and formal argument lists differ in length
It needs ProviderClient
object to be passed as a new argument.
Skip deployment in container mode
In case of consumer driven contracts, there are two kinds of tests - consumer tests and provider tests. Usually in your CI environment you want to run provider tests against two different scenarios
against a master branch - to detect if provider team has done its work
against production - to see if consumer is deployed to production and if the contract is still valid
Test code is exactly the same, but with one difference when we consider using Arquillian. The first one could be implemented as Arquillian incontainer test (using @deployment to deploy the current code, and choosing the container you want to deploy the service), the second one will be exactly the same test, but no deployment phase will be required since application is already deployed.
It would be useful to simply instruct the Arquillian Pact to run the test with -Dignore.deployment=true so it will skip @deployment and lifecycle management of target container.
Notice that this feature would allow us to reuse Arquillian tests to run them against real environments without changing the tests or duplicating them.
Create JBoss Forge addon to scaffold consumer or provider CDC
Update PactJVM version and update PactClientBrooker client
Unable to run Arquillian tests which are not using Algeron when it's on the classpath
When you have algeron on the classpath but also other Arquillian tests, they fail to be executed, as Algeron expects to have pacts defined for them too. Following exception is thrown:
java.lang.IllegalArgumentException: Provider name should be set by using org.arquillian.algeron.pact.provider.spi.Provider
at org.arquillian.algeron.pact.provider.core.PactsRetriever.getPacts(PactsRetriever.java:59)
at org.arquillian.algeron.pact.provider.core.PactsRetriever.retrievePacts(PactsRetriever.java:49)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:498)
at org.jboss.arquillian.core.impl.ObserverImpl.invoke(ObserverImpl.java:86)
at org.jboss.arquillian.core.impl.EventContextImpl.invokeObservers(EventContextImpl.java:103)
at org.jboss.arquillian.core.impl.EventContextImpl.proceed(EventContextImpl.java:90)
at org.jboss.arquillian.test.impl.TestContextHandler.createClassContext(TestContextHandler.java:83)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:498)
at org.jboss.arquillian.core.impl.ObserverImpl.invoke(ObserverImpl.java:86)
at org.jboss.arquillian.core.impl.EventContextImpl.proceed(EventContextImpl.java:95)
at org.jboss.arquillian.test.impl.TestContextHandler.createSuiteContext(TestContextHandler.java:69)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:498)
at org.jboss.arquillian.core.impl.ObserverImpl.invoke(ObserverImpl.java:86)
at org.jboss.arquillian.core.impl.EventContextImpl.proceed(EventContextImpl.java:95)
at org.jboss.arquillian.core.impl.ManagerImpl.fire(ManagerImpl.java:133)
at org.jboss.arquillian.core.impl.ManagerImpl.fire(ManagerImpl.java:105)
at org.jboss.arquillian.test.impl.EventTestRunnerAdaptor.beforeClass(EventTestRunnerAdaptor.java:80)
at org.jboss.arquillian.junit.Arquillian$2.evaluate(Arquillian.java:179)
at org.jboss.arquillian.junit.Arquillian.multiExecute(Arquillian.java:384)
at org.jboss.arquillian.junit.Arquillian.access$200(Arquillian.java:54)
at org.jboss.arquillian.junit.Arquillian$3.evaluate(Arquillian.java:193)
at org.junit.rules.ExternalResource$1.evaluate(ExternalResource.java:48)
at org.junit.contrib.java.lang.system.EnvironmentVariables$EnvironmentVariablesStatement.evaluate(EnvironmentVariables.java:82)
at org.junit.rules.ExternalResource$1.evaluate(ExternalResource.java:48)
at org.junit.rules.ExternalResource$1.evaluate(ExternalResource.java:48)
at org.junit.rules.ExternalResource$1.evaluate(ExternalResource.java:48)
at org.junit.rules.ExternalResource$1.evaluate(ExternalResource.java:48)
at org.junit.rules.RunRules.evaluate(RunRules.java:20)
at org.junit.runners.ParentRunner.run(ParentRunner.java:363)
at org.jboss.arquillian.junit.Arquillian.run(Arquillian.java:148)
at org.junit.runner.JUnitCore.run(JUnitCore.java:137)
at com.intellij.junit4.JUnit4IdeaTestRunner.startRunnerWithArgs(JUnit4IdeaTestRunner.java:68)
at com.intellij.rt.execution.junit.IdeaTestRunner$Repeater.startRunnerWithArgs(IdeaTestRunner.java:47)
at com.intellij.rt.execution.junit.JUnitStarter.prepareStreamsAndStart(JUnitStarter.java:242)
at com.intellij.rt.execution.junit.JUnitStarter.main(JUnitStarter.java:70)
Submit new release candidate
Is it possible to release a new rc version? As #89 is merged it would be great to have this on maven central.
Create modules for complex PactLoaders
Create modules for complex PactLoaders to avoid adding external dependencies to main project. These dependencies might be:
- PactBroker
- PactMaven
- PactShrinkwrap
Using skippingDeployment with Wildfly Swarm returns a NPE
Issue Overview
When using skipping Deployment feature with wildfly swarm makes test throw a NPE. This is because our URL provider extends from standard URL Resource provider and in case of skipDeployment
to false it calls the standard provider. The problem is that swarm also implements its own URL provider https://github.com/wildfly-swarm/wildfly-swarm/blob/b5cb17490ce543f17eed91b22377a38e3e46026c/arquillian/adapter/src/main/java/org/wildfly/swarm/arquillian/adapter/WildFlySwarmExtension.java#L40 so when running the test a NPE is thrown because the standard one does not work with swarm
Pact Url Provider is located at https://github.com/arquillian/arquillian-pact/blob/master/provider/core/src/main/java/org/arquillian/pact/provider/core/deployment/EnvironmentUrlResourceProvider.java
Expected Behaviour
Inject swarm url.
Current Behaviour
NPE
A possible solution might be creating the same class but extending from Swarm ones and depending on classpath adding one or another.
Another option could be create a class that instead of extending from a concrete implementation, extend from OperatesOnDeploymentAwareProvider
and as field contains a ResourceProvider
. Then depending on if swarm provider is on classpath we create and pass through injector this class if not, we use the standard one. Then if skip deployment is false we use the one defined in the field, if not then our own implementation.
Move Target class to SPI
Allow Pact Loader to be specified in configuration file as well
Issue Overview
Currently pact consumer can publish contracts. Configuration parameters are set in arquillian.xml.
In provider side, you can load contracts to verify them, but load configuration comes from annotations.
The idea is to provide to provider part a way to configure loader contracts from arquillian.xml as well.
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. ๐๐๐
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google โค๏ธ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.