# larva-test-builder

> - Most recent LTS version of [node.js](https://nodejs.org/en/) - Ibis Adapter Framework (https://github.com/ibissource/iaf)

Latest version **1.0.14** (published 2018-03-03) · ISC license · 0 weekly downloads

## Install

```sh
npm install larva-test-builder
pnpm add larva-test-builder
yarn add larva-test-builder
bun add larva-test-builder
```

## Health

**Score 15/100 (F)** — status: abandoned.

Positive: no vulnerabilities.

Warnings: low downloads; no types; no esm support.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 1.0.14 |
| Published | 2018-03-03 |
| First published | 2018-03-01 |
| Weekly downloads | 0 |
| License | ISC |
| TypeScript types | none |
| Module format | CommonJS |
| Dependencies | 10 |
| Unpacked size | 15.7 KB |
| Known vulnerabilities | 0 (+2 in 2 direct dependencies) |
| Install scripts | no |
| Author | laurens mäkel |
| Maintainers | laurens-makel |

## Links

- npm: https://www.npmjs.com/package/larva-test-builder
- npm.io page: https://npm.io/package/larva-test-builder

## Dependencies (10)

- [fs](https://npm.io/package/fs.md) 0.0.1-security
- [maven](https://npm.io/package/maven.md) ^4.4.0
- [colors](https://npm.io/package/colors.md) ^1.1.2
- [cheerio](https://npm.io/package/cheerio.md) ^1.0.0-rc.2
- [request](https://npm.io/package/request.md) ^2.83.0
- [inquirer](https://npm.io/package/inquirer.md) ^5.1.0
- [form-data](https://npm.io/package/form-data.md) ^2.3.2
- [xml-parse](https://npm.io/package/xml-parse.md) ^0.3.1
- [xmlbuilder](https://npm.io/package/xmlbuilder.md) ^9.0.7
- [querystring](https://npm.io/package/querystring.md) ^0.2.0

## Recent versions

- 1.0.14 (latest) — 2018-03-03
- 1.0.13 — 2018-03-02
- 1.0.12 — 2018-03-02
- 1.0.11 — 2018-03-02
- 1.0.10 — 2018-03-02
- 1.0.9 — 2018-03-02
- 1.0.8 — 2018-03-02
- 1.0.7 — 2018-03-02
- 1.0.6 — 2018-03-02
- 1.0.5 — 2018-03-01
- 1.0.4 — 2018-03-01
- 1.0.3 — 2018-03-01
- 1.0.2 — 2018-03-01
- 1.0.1 — 2018-03-01
- 1.0.0 — 2018-03-01

## README

# Larva Test Builder - HTTP REST

### Requirements
- Most recent LTS version of [node.js](https://nodejs.org/en/)
- Ibis Adapter Framework (https://github.com/ibissource/iaf) 

### Get up and running
##### Step 1:
Install this package
```sh
$ npm install larva-test-builder --save
```
##### Step 2:
Include this package
```sh
const larvaBuilder = require('larva-test-builder');
```
##### Step 3
Start writing a JSON configuration for your test
```sh
const config = [
	{ 
		method : "POST", 
		configuration : "Users", 
		name : "Hello World",
		url : "/users", 
		javaListener : "PostUsers", 
		statusCode : 201,
		payload : '{"user":{"name":"John Doe!"}}'
	},
	{
		how : "delete",
		table : "user",
	},
	{
		run : true,
		maven : false,
		all : false
	}
]
```
### Step 4 
Create ignoreContentBetweenKeys object
```sh
const ignoreContentBetweenKeys = {
	manageDatabaseRLY : {active: true, start: "<manageDatabaseRLY>", end: " </manageDatabaseRLY>"},
	id : {active: true, start: '"id"', end: "\\n"},
	createdAt : {active: true, start: '"createdAt"', end: "\\n"},
	effectiveFrom : {active: true, start: '"effective_from"', end: "\\n"},
};
```
### Step 5
Initialise larvaBuilder
```sh
const larva = new larvaBuilder({ larva: 'http://localhost/iaf/larva/index.jsp', testDirectory: 'Absolute path to your Larva test dir', rootDirectory : 'Absolute path to your IAF project dir'});
```
### Step 5
Call larva.create()
```sh
larva.create(config, ignoreContentBetweenKeys);
```

### Step 6
Run your .js file and check your console for test results.

---
_Source: https://npm.io/package/larva-test-builder · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
