All Downloads are FREE. Search and download functionalities are using the official Maven repository.

Download JAR files tagged by your with all dependencies

Search JAR files by class name

tagmycode-netbeans from group com.tagmycode (version 2.3.0)

Provides the support for <a href="https://tagmycode.com">TagMyCode</a>. This plugin allows you to manage your own snippets.<br/> <br/> Features:<br/> * Add snippets: you can save your code snippets including description, language, and tags<br/> * List snippets (CRUD): snippets are stored locally and you can filter, sort, create, modify, edit or delete them directly from the IDE<br/> * Quick search: you can search your snippets and insert them directly into the document<br/> <br/> CHANGELOG:<br/> <br/> 2.3.0 (released 2020-07-26)<br/> * published plugin into Apache NetBeans Plugin Portal<br/> * filter snippets by languages<br/> <br/> 2.2.1 (released 2018-01-10)<br/> * Quick Search dialog is now resizable</br> * fixed syntax highlight for PHP and HTML</br> * if refresh token is not valid user will be automatically logged out</br> </br> 2.2.0 (released 2017-11-06)<br/> * snippets management works in offline mode<br/> * autodetect language on new snippet<br/> * added settings dialog with editor theme and font size option<br/> * added title and description to snippet view<br/> * changed open browser class<br/> * text can be dragged into table to create a new snippet<br/> * snippets can be dragged directly into editor and the code are copied<br/> * added "save as file" feature<br/> * added "clone snippet" feature<br/> * added "snippet properties" dialog<br/> * detect binary file<br/> <br/> 2.1.0 (released 2017-04-24)<br/> * moved error messages from dialog to Netbeans Notification Log<br/> * added welcome panel<br/> * about dialog shows plugin version and framework version<br/> * moved storage from JSON to SQL<br/> <br/> 2.0 (released 2016-07-11)<br/> * new user interface<br/> * list of snippets stored locally<br/> * syntax highlight powered by <a href="http://bobbylight.github.io/RSyntaxTextArea/">RSyntaxTextArea</a><br/> * snippets are synchronized with server<br/> * filter snippets<br/> * quick search feature<br/> * insert selected snippet at cursor in document<br/> <br/> 1.1.3 (released 2015-12-18)<br/> * Fix for NetBeans 8.1<br/> <br/> 1.1.2 (released 2014-10-03)<br/> * Switched authentication from OAuth 1.0a to OAuth 2<br/> * Console write also snippet title when new snippet is created (thanks to bejoy)<br/> <br/> 1.1 (released 2014-08-19)<br/> * Added "Search snippets" feature<br/> * Fixed some minor bugs<br/> <br/> 1.0 (released 2014-04-14)<br/> * First release with feature "Create snippet"<br/>

Group: com.tagmycode Artifact: tagmycode-netbeans
Show documentation Show source 
 

0 downloads
Artifact tagmycode-netbeans
Group com.tagmycode
Version 2.3.0
Last update 06. September 2020
Organization not specified
URL https://tagmycode.com
License Apache License 2.0
Dependencies amount 18
Dependencies commons-lang3, rsyntaxtextarea, guava, org-netbeans-api-annotations-common, org-openide-awt, org-netbeans-modules-settings, org-openide-dialogs, org-netbeans-modules-editor, org-netbeans-modules-keyring, org-openide-nodes, org-openide-util, org-openide-loaders, org-openide-windows, org-openide-util-ui, org-openide-text, org-netbeans-api-progress, log4j, tagmycode-plugin-framework,
There are maybe transitive dependencies!

mahout from group org.apache.mahout (version 14.1)

Mahout's goal is to build scalable machine learning libraries. With scalable we mean: Scalable to reasonably large data sets. Our core algorithms for clustering, classification and batch based collaborative filtering are implemented on top of Apache Hadoop using the map/reduce paradigm. However we do not restrict contributions to Hadoop based implementations: Contributions that run on a single node or on a non-Hadoop cluster are welcome as well. The core libraries are highly optimized to allow for good performance also for non-distributed algorithms. Scalable to support your business case. Mahout is distributed under a commercially friendly Apache Software license. Scalable community. The goal of Mahout is to build a vibrant, responsive, diverse community to facilitate discussions not only on the project itself but also on potential use cases. Come to the mailing lists to find out more. Currently Mahout supports mainly four use cases: Recommendation mining takes users' behavior and from that tries to find items users might like. Clustering takes e.g. text documents and groups them into groups of topically related documents. Classification learns from existing categorized documents what documents of a specific category look like and is able to assign unlabelled documents to the (hopefully) correct category. Frequent itemset mining takes a set of item groups (terms in a query session, shopping cart content) and identifies, which individual items usually appear together.

Group: org.apache.mahout Artifact: mahout
Show all versions 
There is no JAR file uploaded. A download is not possible! Please choose another version.
0 downloads
Artifact mahout
Group org.apache.mahout
Version 14.1
Last update 16. July 2020
Organization The Apache Software Foundation
URL http://mahout.apache.org
License Apache License, Version 2.0
Dependencies amount 0
Dependencies No dependencies
There are maybe transitive dependencies!

pact-jvm-consumer-java8_2.12 from group au.com.dius (version 3.6.15)

# pact-jvm-consumer-java8 Provides a Java8 lambda based DSL for use with Junit to build consumer tests. # A Lambda DSL for Pact This is an extension for the pact DSL provided by [pact-jvm-consumer](../pact-jvm-consumer). The difference between the default pact DSL and this lambda DSL is, as the name suggests, the usage of lambdas. The use of lambdas makes the code much cleaner. ## Why a new DSL implementation? The lambda DSL solves the following two main issues. Both are visible in the following code sample: ```java new PactDslJsonArray() .array() # open an array .stringValue(&quot;a1&quot;) # choose the method that is valid for arrays .stringValue(&quot;a2&quot;) # choose the method that is valid for arrays .closeArray() # close the array .array() # open an array .numberValue(1) # choose the method that is valid for arrays .numberValue(2) # choose the method that is valid for arrays .closeArray() # close the array .array() # open an array .object() # now we work with an object .stringValue(&quot;foo&quot;, &quot;Foo&quot;) # choose the method that is valid for objects .closeObject() # close the object and we&apos;re back in the array .closeArray() # close the array ``` ### The existing DSL is quite error-prone Methods may only be called in certain states. For example `object()` may only be called when you&apos;re currently working on an array whereas `object(name)` is only allowed to be called when working on an object. But both of the methods are available. You&apos;ll find out at runtime if you&apos;re using the correct method. Finally, the need for opening and closing objects and arrays makes usage cumbersome. The lambda DSL has no ambiguous methods and there&apos;s no need to close objects and arrays as all the work on such an object is wrapped in a lamda call. ### The existing DSL is hard to read When formatting your source code with an IDE the code becomes hard to read as there&apos;s no indentation possible. Of course, you could do it by hand but we want auto formatting! Auto formatting works great for the new DSL! ```java array.object((o) -&gt; { o.stringValue(&quot;foo&quot;, &quot;Foo&quot;); # an attribute o.stringValue(&quot;bar&quot;, &quot;Bar&quot;); # an attribute o.object(&quot;tar&quot;, (tarObject) -&gt; { # an attribute with a nested object tarObject.stringValue(&quot;a&quot;, &quot;A&quot;); # attribute of the nested object tarObject.stringValue(&quot;b&quot;, &quot;B&quot;); # attribute of the nested object }) }); ``` ## Installation ### Maven ``` &lt;dependency&gt; &lt;groupId&gt;au.com.dius&lt;/groupId&gt; &lt;artifactId&gt;pact-jvm-consumer-java8_2.12&lt;/artifactId&gt; &lt;version&gt;${pact.version}&lt;/version&gt; &lt;/dependency&gt; ``` ## Usage Start with a static import of `LambdaDsl`. This class contains factory methods for the lambda dsl extension. When you come accross the `body()` method of `PactDslWithProvider` builder start using the new extensions. The call to `LambdaDsl` replaces the call to instance `new PactDslJsonArray()` and `new PactDslJsonBody()` of the pact library. ```java io.pactfoundation.consumer.dsl.LambdaDsl.* ``` ### Response body as json array ```java import static io.pactfoundation.consumer.dsl.LambdaDsl.newJsonArray; ... PactDslWithProvider builder = ... builder.given(&quot;some state&quot;) .uponReceiving(&quot;a request&quot;) .path(&quot;/my-app/my-service&quot;) .method(&quot;GET&quot;) .willRespondWith() .status(200) .body(newJsonArray((a) -&gt; { a.stringValue(&quot;a1&quot;); a.stringValue(&quot;a2&quot;); }).build()); ``` ### Response body as json object ```java import static io.pactfoundation.consumer.dsl.LambdaDsl.newJsonBody; ... PactDslWithProvider builder = ... builder.given(&quot;some state&quot;) .uponReceiving(&quot;a request&quot;) .path(&quot;/my-app/my-service&quot;) .method(&quot;GET&quot;) .willRespondWith() .status(200) .body(newJsonBody((o) -&gt; { o.stringValue(&quot;foo&quot;, &quot;Foo&quot;); o.stringValue(&quot;bar&quot;, &quot;Bar&quot;); }).build()); ``` ### Examples #### Simple Json object When creating simple json structures the difference between the two approaches isn&apos;t big. ##### JSON ```json { &quot;bar&quot;: &quot;Bar&quot;, &quot;foo&quot;: &quot;Foo&quot; } ``` ##### Pact DSL ```java new PactDslJsonBody() .stringValue(&quot;foo&quot;, &quot;Foo&quot;) .stringValue(&quot;bar&quot;, &quot;Bar&quot;) ``` ##### Lambda DSL ```java newJsonBody((o) -&gt; { o.stringValue(&quot;foo&quot;, &quot;Foo&quot;); o.stringValue(&quot;bar&quot;, &quot;Bar&quot;); }).build(); ``` #### An array of arrays When we come to more complex constructs with arrays and nested objects the beauty of lambdas become visible! ##### JSON ```json [ [&quot;a1&quot;, &quot;a2&quot;], [1, 2], [{&quot;foo&quot;: &quot;Foo&quot;}] ] ``` ##### Pact DSL ```java new PactDslJsonArray() .array() .stringValue(&quot;a1&quot;) .stringValue(&quot;a2&quot;) .closeArray() .array() .numberValue(1) .numberValue(2) .closeArray() .array() .object() .stringValue(&quot;foo&quot;, &quot;Foo&quot;) .closeObject() .closeArray(); ``` ##### Lambda DSL ```java newJsonArray((rootArray) -&gt; { rootArray.array((a) -&gt; a.stringValue(&quot;a1&quot;).stringValue(&quot;a2&quot;)); rootArray.array((a) -&gt; a.numberValue(1).numberValue(2)); rootArray.array((a) -&gt; a.object((o) -&gt; o.stringValue(&quot;foo&quot;, &quot;Foo&quot;))); }).build(); ``` `object` is a reserved word in Kotlin. To allow using the DSL without escaping, a Kotlin extension `newObject` is available: ```kotlin newJsonArray { rootArray -&gt; rootArray.array { a -&gt; a.stringValue(&quot;a1&quot;).stringValue(&quot;a2&quot;) } rootArray.array { a -&gt; a.numberValue(1).numberValue(2) } rootArray.array { a -&gt; a.newObject { o -&gt; o.stringValue(&quot;foo&quot;, &quot;Foo&quot;) } } }.build(); ```

Group: au.com.dius Artifact: pact-jvm-consumer-java8_2.12
Show all versions Show documentation Show source 
 

0 downloads
Artifact pact-jvm-consumer-java8_2.12
Group au.com.dius
Version 3.6.15
Last update 29. April 2020
Organization not specified
URL https://github.com/DiUS/pact-jvm
License Apache 2
Dependencies amount 1
Dependencies pact-jvm-consumer_2.12,
There are maybe transitive dependencies!

pact-jvm-provider-junit5-spring from group au.com.dius (version 4.0.10)

# Pact Spring/JUnit5 Support This module extends the base [Pact JUnit5 module](../pact-jvm-provider-junit5). See that for more details. For writing Spring Pact verification tests with JUnit 5, there is an JUnit 5 Invocation Context Provider that you can use with the `@TestTemplate` annotation. This will generate a test for each interaction found for the pact files for the provider. To use it, add the `@Provider` and `@ExtendWith(SpringExtension.class)` and one of the pact source annotations to your test class (as per a JUnit 5 test), then add a method annotated with `@TestTemplate` and `@ExtendWith(PactVerificationSpringProvider.class)` that takes a `PactVerificationContext` parameter. You will need to call `verifyInteraction()` on the context parameter in your test template method. For example: ```java @ExtendWith(SpringExtension.class) @SpringBootTest(webEnvironment = SpringBootTest.WebEnvironment.DEFINED_PORT) @Provider(&quot;Animal Profile Service&quot;) @PactBroker public class ContractVerificationTest { @TestTemplate @ExtendWith(PactVerificationSpringProvider.class) void pactVerificationTestTemplate(PactVerificationContext context) { context.verifyInteraction(); } } ``` You will now be able to setup all the required properties using the Spring context, e.g. creating an application YAML file in the test resources: ```yaml pactbroker: host: your.broker.host auth: username: broker-user password: broker.password ``` You can also run pact tests against `MockMvc` without need to spin up the whole application context which takes time and often requires more additional setup (e.g. database). In order to run lightweight tests just use `@WebMvcTest` from Spring and `MockMvcTestTarget` as a test target before each test. For example: ```java @WebMvcTest @Provider(&quot;myAwesomeService&quot;) @PactBroker class ContractVerificationTest { @Autowired private MockMvc mockMvc; @TestTemplate @ExtendWith(PactVerificationInvocationContextProvider.class) void pactVerificationTestTemplate(PactVerificationContext context) { context.verifyInteraction(); } @BeforeEach void before(PactVerificationContext context) { context.setTarget(new MockMvcTestTarget(mockMvc)); } } ``` You can also use `MockMvcTestTarget` for tests without spring context by providing the controllers manually. For example: ```java @Provider(&quot;myAwesomeService&quot;) @PactFolder(&quot;pacts&quot;) class MockMvcTestTargetStandaloneMockMvcTestJava { @TestTemplate @ExtendWith(PactVerificationInvocationContextProvider.class) void pactVerificationTestTemplate(PactVerificationContext context) { context.verifyInteraction(); } @BeforeEach void before(PactVerificationContext context) { MockMvcTestTarget testTarget = new MockMvcTestTarget(); testTarget.setControllers(new DataResource()); context.setTarget(testTarget); } @RestController static class DataResource { @GetMapping(&quot;/data&quot;) @ResponseStatus(HttpStatus.NO_CONTENT) void getData(@RequestParam(&quot;ticketId&quot;) String ticketId) { } } } ``` **Important:** Since `@WebMvcTest` starts only Spring MVC components you can&apos;t use `PactVerificationSpringProvider` and need to fallback to `PactVerificationInvocationContextProvider`

Group: au.com.dius Artifact: pact-jvm-provider-junit5-spring
Show all versions Show documentation Show source 
 

0 downloads
Artifact pact-jvm-provider-junit5-spring
Group au.com.dius
Version 4.0.10
Last update 18. April 2020
Organization not specified
URL https://github.com/DiUS/pact-jvm
License Apache 2
Dependencies amount 0
Dependencies No dependencies
There are maybe transitive dependencies!

pact-jvm-consumer-java8 from group au.com.dius (version 4.0.10)

# pact-jvm-consumer-java8 Provides a Java8 lambda based DSL for use with Junit to build consumer tests. # A Lambda DSL for Pact This is an extension for the pact DSL provided by [pact-jvm-consumer](../pact-jvm-consumer). The difference between the default pact DSL and this lambda DSL is, as the name suggests, the usage of lambdas. The use of lambdas makes the code much cleaner. ## Why a new DSL implementation? The lambda DSL solves the following two main issues. Both are visible in the following code sample: ```java new PactDslJsonArray() .array() # open an array .stringValue(&quot;a1&quot;) # choose the method that is valid for arrays .stringValue(&quot;a2&quot;) # choose the method that is valid for arrays .closeArray() # close the array .array() # open an array .numberValue(1) # choose the method that is valid for arrays .numberValue(2) # choose the method that is valid for arrays .closeArray() # close the array .array() # open an array .object() # now we work with an object .stringValue(&quot;foo&quot;, &quot;Foo&quot;) # choose the method that is valid for objects .closeObject() # close the object and we&apos;re back in the array .closeArray() # close the array ``` ### The existing DSL is quite error-prone Methods may only be called in certain states. For example `object()` may only be called when you&apos;re currently working on an array whereas `object(name)` is only allowed to be called when working on an object. But both of the methods are available. You&apos;ll find out at runtime if you&apos;re using the correct method. Finally, the need for opening and closing objects and arrays makes usage cumbersome. The lambda DSL has no ambiguous methods and there&apos;s no need to close objects and arrays as all the work on such an object is wrapped in a lamda call. ### The existing DSL is hard to read When formatting your source code with an IDE the code becomes hard to read as there&apos;s no indentation possible. Of course, you could do it by hand but we want auto formatting! Auto formatting works great for the new DSL! ```java array.object((o) -&gt; { o.stringValue(&quot;foo&quot;, &quot;Foo&quot;); # an attribute o.stringValue(&quot;bar&quot;, &quot;Bar&quot;); # an attribute o.object(&quot;tar&quot;, (tarObject) -&gt; { # an attribute with a nested object tarObject.stringValue(&quot;a&quot;, &quot;A&quot;); # attribute of the nested object tarObject.stringValue(&quot;b&quot;, &quot;B&quot;); # attribute of the nested object }) }); ``` ## Installation ### Maven ``` &lt;dependency&gt; &lt;groupId&gt;au.com.dius&lt;/groupId&gt; &lt;artifactId&gt;pact-jvm-consumer-java8_2.12&lt;/artifactId&gt; &lt;version&gt;${pact.version}&lt;/version&gt; &lt;/dependency&gt; ``` ## Usage Start with a static import of `LambdaDsl`. This class contains factory methods for the lambda dsl extension. When you come accross the `body()` method of `PactDslWithProvider` builder start using the new extensions. The call to `LambdaDsl` replaces the call to instance `new PactDslJsonArray()` and `new PactDslJsonBody()` of the pact library. ```java io.pactfoundation.consumer.dsl.LambdaDsl.* ``` ### Response body as json array ```java import static io.pactfoundation.consumer.dsl.LambdaDsl.newJsonArray; ... PactDslWithProvider builder = ... builder.given(&quot;some state&quot;) .uponReceiving(&quot;a request&quot;) .path(&quot;/my-app/my-service&quot;) .method(&quot;GET&quot;) .willRespondWith() .status(200) .body(newJsonArray((a) -&gt; { a.stringValue(&quot;a1&quot;); a.stringValue(&quot;a2&quot;); }).build()); ``` ### Response body as json object ```java import static io.pactfoundation.consumer.dsl.LambdaDsl.newJsonBody; ... PactDslWithProvider builder = ... builder.given(&quot;some state&quot;) .uponReceiving(&quot;a request&quot;) .path(&quot;/my-app/my-service&quot;) .method(&quot;GET&quot;) .willRespondWith() .status(200) .body(newJsonBody((o) -&gt; { o.stringValue(&quot;foo&quot;, &quot;Foo&quot;); o.stringValue(&quot;bar&quot;, &quot;Bar&quot;); }).build()); ``` ### Examples #### Simple Json object When creating simple json structures the difference between the two approaches isn&apos;t big. ##### JSON ```json { &quot;bar&quot;: &quot;Bar&quot;, &quot;foo&quot;: &quot;Foo&quot; } ``` ##### Pact DSL ```java new PactDslJsonBody() .stringValue(&quot;foo&quot;, &quot;Foo&quot;) .stringValue(&quot;bar&quot;, &quot;Bar&quot;) ``` ##### Lambda DSL ```java newJsonBody((o) -&gt; { o.stringValue(&quot;foo&quot;, &quot;Foo&quot;); o.stringValue(&quot;bar&quot;, &quot;Bar&quot;); }).build(); ``` #### An array of arrays When we come to more complex constructs with arrays and nested objects the beauty of lambdas become visible! ##### JSON ```json [ [&quot;a1&quot;, &quot;a2&quot;], [1, 2], [{&quot;foo&quot;: &quot;Foo&quot;}] ] ``` ##### Pact DSL ```java new PactDslJsonArray() .array() .stringValue(&quot;a1&quot;) .stringValue(&quot;a2&quot;) .closeArray() .array() .numberValue(1) .numberValue(2) .closeArray() .array() .object() .stringValue(&quot;foo&quot;, &quot;Foo&quot;) .closeObject() .closeArray(); ``` ##### Lambda DSL ```java newJsonArray((rootArray) -&gt; { rootArray.array((a) -&gt; a.stringValue(&quot;a1&quot;).stringValue(&quot;a2&quot;)); rootArray.array((a) -&gt; a.numberValue(1).numberValue(2)); rootArray.array((a) -&gt; a.object((o) -&gt; o.stringValue(&quot;foo&quot;, &quot;Foo&quot;))); }).build(); ``` ##### Kotlin Lambda DSL ```kotlin newJsonArray { newArray { stringValue(&quot;a1&quot;) stringValue(&quot;a2&quot;) } newArray { numberValue(1) numberValue(2) } newArray { newObject { stringValue(&quot;foo&quot;, &quot;Foo&quot;) } } } ```

Group: au.com.dius Artifact: pact-jvm-consumer-java8
Show all versions Show documentation Show source 
 

0 downloads
Artifact pact-jvm-consumer-java8
Group au.com.dius
Version 4.0.10
Last update 18. April 2020
Organization not specified
URL https://github.com/DiUS/pact-jvm
License Apache 2
Dependencies amount 1
Dependencies pact-jvm-consumer,
There are maybe transitive dependencies!

HockeySDK from group net.hockeyapp.android (version 5.2.0)

HockeySDK-Android implements support for using HockeyApp in your Android application. The following features are currently supported: Collect crash reports:If your app crashes, a crash log is written to the device's storage. If the user starts the app again, they will be asked asked to submit the crash report to HockeyApp. This works for both beta and live apps, i.e. those submitted to Google Play or other app stores. Crash logs contain viable information for you to help resolve the issue. Furthermore, you as a developer can add additional information to the report as well. Update Alpha/Beta apps: The app will check with HockeyApp if a new version for your alpha/beta build is available. If yes, it will show a dialog to users and let them see the release notes, the version history and start the installation process right away. You can even force the installation of certain updates. User Metrics: Understand user behavior to improve your app. Track usage through daily and monthly active users. Monitor crash impacted users. Measure customer engagement through session count. Add custom tracking calls to learn which features your users are actually using. This feature requires a minimum API level of 14 (Android 4.x Ice Cream Sandwich). Feedback: Besides crash reports, collecting feedback from your users from within your app is a great option to help with improving your app. You act on and answer feedback directly from the HockeyApp backend. Authenticate: Identify and authenticate users against your registered testers with the HockeyApp backend.

Group: net.hockeyapp.android Artifact: HockeySDK
Show all versions Show documentation 
There is no JAR file uploaded. A download is not possible! Please choose another version.
0 downloads
Artifact HockeySDK
Group net.hockeyapp.android
Version 5.2.0
Last update 21. May 2019
Organization not specified
URL https://github.com/bitstadium/hockeysdk-android
License MIT
Dependencies amount 0
Dependencies No dependencies
There are maybe transitive dependencies!

pact-jvm-provider-junit5_2.11 from group au.com.dius (version 3.5.24)

# Pact Junit 5 Extension ## Overview For writing Pact verification tests with JUnit 5, there is an JUnit 5 Invocation Context Provider that you can use with the `@TestTemplate` annotation. This will generate a test for each interaction found for the pact files for the provider. To use it, add the `@Provider` and one of the pact source annotations to your test class (as per a JUnit 4 test), then add a method annotated with `@TestTemplate` and `@ExtendWith(PactVerificationInvocationContextProvider.class)` that takes a `PactVerificationContext` parameter. You will need to call `verifyInteraction()` on the context parameter in your test template method. For example: ```java @Provider(&quot;myAwesomeService&quot;) @PactFolder(&quot;pacts&quot;) public class ContractVerificationTest { @TestTemplate @ExtendWith(PactVerificationInvocationContextProvider.class) void pactVerificationTestTemplate(PactVerificationContext context) { context.verifyInteraction(); } } ``` For details on the provider and pact source annotations, refer to the [Pact junit runner](../pact-jvm-provider-junit/README.md) docs. ## Test target You can set the test target (the object that defines the target of the test, which should point to your provider) on the `PactVerificationContext`, but you need to do this in a before test method (annotated with `@BeforeEach`). There are three different test targets you can use: `HttpTestTarget`, `HttpsTestTarget` and `AmpqTestTarget`. For example: ```java @BeforeEach void before(PactVerificationContext context) { context.setTarget(HttpTestTarget.fromUrl(new URL(myProviderUrl))); // or something like // context.setTarget(new HttpTestTarget(&quot;localhost&quot;, myProviderPort, &quot;/&quot;)); } ``` ## Provider State Methods Provider State Methods work in the same way as with JUnit 4 tests, refer to the [Pact junit runner](../pact-jvm-provider-junit/README.md) docs. ## Modifying the requests before they are sent **Important Note:** You should only use this feature for things that can not be persisted in the pact file. By modifying the request, you are potentially modifying the contract from the consumer tests! Sometimes you may need to add things to the requests that can&apos;t be persisted in a pact file. Examples of these would be authentication tokens, which have a small life span. The Http and Https test targets support injecting the request that will executed into the test template method. You can then add things to the request before calling the `verifyInteraction()` method. For example to add a header: ```java @TestTemplate @ExtendWith(PactVerificationInvocationContextProvider.class) void testTemplate(PactVerificationContext context, HttpRequest request) { // This will add a header to the request request.addHeader(&quot;X-Auth-Token&quot;, &quot;1234&quot;); context.verifyInteraction(); } ``` ## Objects that can be injected into the test methods You can inject the following objects into your test methods (just like the `PactVerificationContext`). They will be null if injected before the supported phase. | Object | Can be injected from phase | Description | | ------ | --------------- | ----------- | | PactVerificationContext | @BeforeEach | The context to use to execute the interaction test | | Pact | any | The Pact model for the test | | Interaction | any | The Interaction model for the test | | HttpRequest | @TestTemplate | The request that is going to be executed (only for HTTP and HTTPS targets) | | ProviderVerifier | @TestTemplate | The verifier instance that is used to verify the interaction |

Group: au.com.dius Artifact: pact-jvm-provider-junit5_2.11
Show all versions Show documentation Show source 
 

2 downloads
Artifact pact-jvm-provider-junit5_2.11
Group au.com.dius
Version 3.5.24
Last update 04. November 2018
Organization not specified
URL https://github.com/DiUS/pact-jvm
License Apache 2
Dependencies amount 9
Dependencies kotlin-stdlib-jdk8, kotlin-reflect, slf4j-api, groovy-all, kotlin-logging, scala-library, scala-logging_2.11, pact-jvm-provider-junit_2.11, junit-jupiter-api,
There are maybe transitive dependencies!

pact-jvm-consumer-junit5_2.11 from group au.com.dius (version 3.5.24)

pact-jvm-consumer-junit5 ======================== JUnit 5 support for Pact consumer tests ## Dependency The library is available on maven central using: * group-id = `au.com.dius` * artifact-id = `pact-jvm-consumer-junit5_2.12` * version-id = `3.5.x` ## Usage ### 1. Add the Pact consumer test extension to the test class. To write Pact consumer tests with JUnit 5, you need to add `@ExtendWith(PactConsumerTestExt)` to your test class. This replaces the `PactRunner` used for JUnit 4 tests. The rest of the test follows a similar pattern as for JUnit 4 tests. ```java @ExtendWith(PactConsumerTestExt.class) class ExampleJavaConsumerPactTest { ``` ### 2. create a method annotated with `@Pact` that returns the interactions for the test For each test (as with JUnit 4), you need to define a method annotated with the `@Pact` annotation that returns the interactions for the test. ```java @Pact(provider=&quot;test_provider&quot;, consumer=&quot;test_consumer&quot;) public RequestResponsePact createPact(PactDslWithProvider builder) { return builder .given(&quot;test state&quot;) .uponReceiving(&quot;ExampleJavaConsumerPactTest test interaction&quot;) .path(&quot;/&quot;) .method(&quot;GET&quot;) .willRespondWith() .status(200) .body(&quot;{\&quot;responsetest\&quot;: true}&quot;) .toPact(); } ``` ### 3. Link the mock server with the interactions for the test with `@PactTestFor` Then the final step is to use the `@PactTestFor` annotation to tell the Pact extension how to setup the Pact test. You can either put this annotation on the test class, or on the test method. For examples see [ArticlesTest](src/test/java/au/com/dius/pact/consumer/junit5/ArticlesTest.java) and [MultiTest](src/test/groovy/au/com/dius/pact/consumer/junit5/MultiTest.groovy). The `@PactTestFor` annotation allows you to control the mock server in the same way as the JUnit 4 `PactProviderRule`. It allows you to set the hostname to bind to (default is `localhost`) and the port (default is to use a random port). You can also set the Pact specification version to use (default is V3). ```java @ExtendWith(PactConsumerTestExt.class) @PactTestFor(providerName = &quot;ArticlesProvider&quot;, port = &quot;1234&quot;) public class ExampleJavaConsumerPactTest { ``` **NOTE on the hostname**: The mock server runs in the same JVM as the test, so the only valid values for hostname are: | hostname | result | | -------- | ------ | | `localhost` | binds to the address that localhost points to (normally the loopback adapter) | | `127.0.0.1` or `::1` | binds to the loopback adapter | | host name | binds to the default interface that the host machines DNS name resolves to | | `0.0.0.0` or `::` | binds to the all interfaces on the host machine | #### Matching the interactions by provider name If you set the `providerName` on the `@PactTestFor` annotation, then the first method with a `@Pact` annotation with the same provider name will be used. See [ArticlesTest](src/test/java/au/com/dius/pact/consumer/junit5/ArticlesTest.java) for an example. #### Matching the interactions by method name If you set the `pactMethod` on the `@PactTestFor` annotation, then the method with the provided name will be used (it still needs a `@Pact` annotation). See [MultiTest](src/test/groovy/au/com/dius/pact/consumer/junit5/MultiTest.groovy) for an example. ### Injecting the mock server into the test You can get the mock server injected into the test method by adding a `MockServer` parameter to the test method. ```java @Test void test(MockServer mockServer) { HttpResponse httpResponse = Request.Get(mockServer.getUrl() + &quot;/articles.json&quot;).execute().returnResponse(); assertThat(httpResponse.getStatusLine().getStatusCode(), is(equalTo(200))); } ``` This helps with getting the base URL of the mock server, especially when a random port is used. ## Unsupported The current implementation does not support tests with multiple providers. This will be added in a later release.

Group: au.com.dius Artifact: pact-jvm-consumer-junit5_2.11
Show all versions Show documentation Show source 
 

1 downloads
Artifact pact-jvm-consumer-junit5_2.11
Group au.com.dius
Version 3.5.24
Last update 04. November 2018
Organization not specified
URL https://github.com/DiUS/pact-jvm
License Apache 2
Dependencies amount 9
Dependencies kotlin-stdlib-jdk8, kotlin-reflect, slf4j-api, groovy-all, kotlin-logging, scala-library, scala-logging_2.11, pact-jvm-consumer_2.11, junit-jupiter-api,
There are maybe transitive dependencies!

pact-jvm-consumer-java8_2.11 from group au.com.dius (version 3.5.24)

# pact-jvm-consumer-java8 Provides a Java8 lambda based DSL for use with Junit to build consumer tests. # A Lambda DSL for Pact This is an extension for the pact DSL provided by [pact-jvm-consumer](../pact-jvm-consumer). The difference between the default pact DSL and this lambda DSL is, as the name suggests, the usage of lambdas. The use of lambdas makes the code much cleaner. ## Why a new DSL implementation? The lambda DSL solves the following two main issues. Both are visible in the following code sample: ```java new PactDslJsonArray() .array() # open an array .stringValue(&quot;a1&quot;) # choose the method that is valid for arrays .stringValue(&quot;a2&quot;) # choose the method that is valid for arrays .closeArray() # close the array .array() # open an array .numberValue(1) # choose the method that is valid for arrays .numberValue(2) # choose the method that is valid for arrays .closeArray() # close the array .array() # open an array .object() # now we work with an object .stringValue(&quot;foo&quot;, &quot;Foo&quot;) # choose the method that is valid for objects .closeObject() # close the object and we&apos;re back in the array .closeArray() # close the array ``` ### The existing DSL is quite error-prone Methods may only be called in certain states. For example `object()` may only be called when you&apos;re currently working on an array whereas `object(name)` is only allowed to be called when working on an object. But both of the methods are available. You&apos;ll find out at runtime if you&apos;re using the correct method. Finally, the need for opening and closing objects and arrays makes usage cumbersome. The lambda DSL has no ambiguous methods and there&apos;s no need to close objects and arrays as all the work on such an object is wrapped in a lamda call. ### The existing DSL is hard to read When formatting your source code with an IDE the code becomes hard to read as there&apos;s no indentation possible. Of course, you could do it by hand but we want auto formatting! Auto formatting works great for the new DSL! ```java array.object((o) -&gt; { o.stringValue(&quot;foo&quot;, &quot;Foo&quot;); # an attribute o.stringValue(&quot;bar&quot;, &quot;Bar&quot;); # an attribute o.object(&quot;tar&quot;, (tarObject) -&gt; { # an attribute with a nested object tarObject.stringValue(&quot;a&quot;, &quot;A&quot;); # attribute of the nested object tarObject.stringValue(&quot;b&quot;, &quot;B&quot;); # attribute of the nested object }) }); ``` ## Installation ### Maven ``` &lt;dependency&gt; &lt;groupId&gt;au.com.dius&lt;/groupId&gt; &lt;artifactId&gt;pact-jvm-consumer-java8_2.12&lt;/artifactId&gt; &lt;version&gt;${pact.version}&lt;/version&gt; &lt;/dependency&gt; ``` ## Usage Start with a static import of `LambdaDsl`. This class contains factory methods for the lambda dsl extension. When you come accross the `body()` method of `PactDslWithProvider` builder start using the new extensions. The call to `LambdaDsl` replaces the call to instance `new PactDslJsonArray()` and `new PactDslJsonBody()` of the pact library. ```java io.pactfoundation.consumer.dsl.LambdaDsl.* ``` ### Response body as json array ```java import static io.pactfoundation.consumer.dsl.LambdaDsl.newJsonArray; ... PactDslWithProvider builder = ... builder.given(&quot;some state&quot;) .uponReceiving(&quot;a request&quot;) .path(&quot;/my-app/my-service&quot;) .method(&quot;GET&quot;) .willRespondWith() .status(200) .body(newJsonArray((a) -&gt; { a.stringValue(&quot;a1&quot;); a.stringValue(&quot;a2&quot;); }).build()); ``` ### Response body as json object ```java import static io.pactfoundation.consumer.dsl.LambdaDsl.newJsonBody; ... PactDslWithProvider builder = ... builder.given(&quot;some state&quot;) .uponReceiving(&quot;a request&quot;) .path(&quot;/my-app/my-service&quot;) .method(&quot;GET&quot;) .willRespondWith() .status(200) .body(newJsonBody((o) -&gt; { o.stringValue(&quot;foo&quot;, &quot;Foo&quot;); o.stringValue(&quot;bar&quot;, &quot;Bar&quot;); }).build()); ``` ### Examples #### Simple Json object When creating simple json structures the difference between the two approaches isn&apos;t big. ##### JSON ```json { &quot;bar&quot;: &quot;Bar&quot;, &quot;foo&quot;: &quot;Foo&quot; } ``` ##### Pact DSL ```java new PactDslJsonBody() .stringValue(&quot;foo&quot;, &quot;Foo&quot;) .stringValue(&quot;bar&quot;, &quot;Bar&quot;) ``` ##### Lambda DSL ```java newJsonBody((o) -&gt; { o.stringValue(&quot;foo&quot;, &quot;Foo&quot;); o.stringValue(&quot;bar&quot;, &quot;Bar&quot;); }).build() ``` #### An array of arrays When we come to more complex constructs with arrays and nested objects the beauty of lambdas become visible! ##### JSON ```json [ [&quot;a1&quot;, &quot;a2&quot;], [1, 2], [{&quot;foo&quot;: &quot;Foo&quot;}] ] ``` ##### Pact DSL ```java new PactDslJsonArray() .array() .stringValue(&quot;a1&quot;) .stringValue(&quot;a2&quot;) .closeArray() .array() .numberValue(1) .numberValue(2) .closeArray() .array() .object() .stringValue(&quot;foo&quot;, &quot;Foo&quot;) .closeObject() .closeArray() ``` ##### Lambda DSL ```java newJsonArray((rootArray) -&gt; { rootArray.array((a) -&gt; a.stringValue(&quot;a1&quot;).stringValue(&quot;a2&quot;)); rootArray.array((a) -&gt; a.numberValue(1).numberValue(2)); rootArray.array((a) -&gt; a.object((o) -&gt; o.stringValue(&quot;foo&quot;, &quot;Foo&quot;)); }).build() ```

Group: au.com.dius Artifact: pact-jvm-consumer-java8_2.11
Show all versions Show documentation Show source 
 

3 downloads
Artifact pact-jvm-consumer-java8_2.11
Group au.com.dius
Version 3.5.24
Last update 04. November 2018
Organization not specified
URL https://github.com/DiUS/pact-jvm
License Apache 2
Dependencies amount 8
Dependencies kotlin-stdlib-jdk8, kotlin-reflect, slf4j-api, groovy-all, kotlin-logging, scala-library, scala-logging_2.11, pact-jvm-consumer-junit_2.11,
There are maybe transitive dependencies!

adp from group de.cit-ec.tcs.alignment (version 3.1.1)

This module contains a more general approach to construct AlignmentAlgorithms by relying on the theoretical concept of Algebraic Dynamic Programming (ADP) as developed by Giegerich et al. ADP defines four ingredients for an alignment algorithm: 1.) A signature that defines the permitted alignment operations. Operations are just function templates with an associated arity, meaning the number of arguments it takes from the left sequence and from the right sequence. In the TCSAlignmentToolbox we have a fixed signature with the following operations: REPLACEMENT(1, 1), DELETION(1, 0), INSERTION(0, 1), SKIPDELETION(1, 0) and SKIPINSERTION(0, 1) 2.) A regular tree grammar that produces alignments, that is: sequences of operations, in a restricted fashion. 3.) An algebra that can translate such trees to a cost. In the TCSAlignmentToolbox this is a Comparator. 4.) A choice function, in case of the TCSAlignmentToolbox: the strict minimum or the soft minimum. An alignment algorithm in the TCSAlignmentToolbox sense of the word then is the combination of choice function and grammar. While we provide hardcoded versions of these combinations in the main package, the adp package allows you to create your own grammars. You can combine them with a choice function by instantiating one of the Algorithm classes provided in this package with a grammar of your choice. For example: AlignmentAlgorithm algo = new SoftADPScoreAlgorithm(my_grammar, comparator); creates an alignment algorithm that implicitly produces all possible alignments your grammar can construct with the given input, translates them to a cost using the algebra/comparator you provided and applies the soft minimum to return the score. This all gets efficient by dynamic programming. Note that there is runtime overhead when using this method in comparison with the hardcoded algorithms. But for complicated grammars this is a much easier way to go. For more information on the theory, please refer to my master's thesis: "Adaptive Affine Sequence Alignment using Algebraic Dynamic Programming"

Group: de.cit-ec.tcs.alignment Artifact: adp
Show all versions Show documentation Show source 
 

0 downloads
Artifact adp
Group de.cit-ec.tcs.alignment
Version 3.1.1
Last update 26. October 2018
Organization not specified
URL http://openresearch.cit-ec.de/projects/tcs
License The GNU Affero General Public License, Version 3
Dependencies amount 1
Dependencies algorithms,
There are maybe transitive dependencies!



Page 653 from 658 (items total 6576)


© 2015 - 2024 Weber Informatics LLC | Privacy Policy