Browse Source

Rename to keyv-test-suite

emp
Luke Childs 7 years ago
committed by Jytesh
parent
commit
3a445e36af
  1. 20
      packages/keyv-test-suite/README.md
  2. 8
      packages/keyv-test-suite/package.json
  3. 4
      packages/keyv-test-suite/test/unit.js

20
packages/keyv-test-suite/README.md

@ -1,10 +1,10 @@
# keyv-api-tests
# keyv-test-suite
> Test suite for Keyv API compliancy
[![Build Status](https://travis-ci.org/lukechilds/keyv-api-tests.svg?branch=master)](https://travis-ci.org/lukechilds/keyv-api-tests)
[![Coverage Status](https://coveralls.io/repos/github/lukechilds/keyv-api-tests/badge.svg?branch=master)](https://coveralls.io/github/lukechilds/keyv-api-tests?branch=master)
[![npm](https://img.shields.io/npm/v/keyv-api-tests.svg)](https://www.npmjs.com/package/keyv-api-tests)
[![Build Status](https://travis-ci.org/lukechilds/keyv-test-suite.svg?branch=master)](https://travis-ci.org/lukechilds/keyv-test-suite)
[![Coverage Status](https://coveralls.io/repos/github/lukechilds/keyv-test-suite/badge.svg?branch=master)](https://coveralls.io/github/lukechilds/keyv-test-suite?branch=master)
[![npm](https://img.shields.io/npm/v/keyv-test-suite.svg)](https://www.npmjs.com/package/keyv-test-suite)
Complete [AVA](https://github.com/avajs/ava) test suite to test a [Keyv](https://github.com/lukechilds/keyv) storage adapter for API compliancy.
@ -12,13 +12,13 @@ Complete [AVA](https://github.com/avajs/ava) test suite to test a [Keyv](https:/
### Install
Install AVA, Keyv and `keyv-api-tests` as development dependencies.
Install AVA, Keyv and `keyv-test-suite` as development dependencies.
```shell
npm install --save-dev ava keyv keyv-api-tests
npm install --save-dev ava keyv keyv-test-suite
```
Then update `keyv` and `keyv-api-tests` versions to `*` in `package.json` to ensure you're always testing against the latest version.
Then update `keyv` and `keyv-test-suite` versions to `*` in `package.json` to ensure you're always testing against the latest version.
### Create Test File
@ -26,12 +26,12 @@ Then update `keyv` and `keyv-api-tests` versions to `*` in `package.json` to ens
```js
import test from 'ava';
import keyvApiTests from 'keyv-api-tests';
import keyvTestSuite from 'keyv-test-suite';
import Keyv from 'keyv';
import KeyvStore from './';
const store = new KeyvStore();
keyvApiTests(test, Keyv, store);
keyvTestSuite(test, Keyv, store);
```
Where `KeyvStore` is your storage adapter.
@ -60,7 +60,7 @@ script: npm test
## Example
Take a look at [keyv-redis](https://github.com/lukechilds/keyv-redis) for an example of an existing storage adapter using `keyv-api-tests`.
Take a look at [keyv-redis](https://github.com/lukechilds/keyv-redis) for an example of an existing storage adapter using `keyv-test-suite`.
## License

8
packages/keyv-test-suite/package.json

@ -1,5 +1,5 @@
{
"name": "keyv-api-tests",
"name": "keyv-test-suite",
"version": "1.2.0",
"description": "Test suite for Keyv API compliancy",
"main": "dist/index.js",
@ -23,7 +23,7 @@
},
"repository": {
"type": "git",
"url": "git+https://github.com/lukechilds/keyv-api-tests.git"
"url": "git+https://github.com/lukechilds/keyv-test-suite.git"
},
"keywords": [
"key",
@ -35,9 +35,9 @@
"author": "Luke Childs <lukechilds123@gmail.com> (http://lukechilds.co.uk)",
"license": "MIT",
"bugs": {
"url": "https://github.com/lukechilds/keyv-api-tests/issues"
"url": "https://github.com/lukechilds/keyv-test-suite/issues"
},
"homepage": "https://github.com/lukechilds/keyv-api-tests",
"homepage": "https://github.com/lukechilds/keyv-test-suite",
"dependencies": {
"delay": "^2.0.0"
},

4
packages/keyv-test-suite/test/unit.js

@ -1,6 +1,6 @@
import test from 'ava';
import Keyv from 'keyv';
import keyvApiTests from '../';
import keyvTestSuite from '../';
const store = new Map();
keyvApiTests(test, Keyv, store);
keyvTestSuite(test, Keyv, store);

Loading…
Cancel
Save