codeception/aerospike-module

Aerospike Module for Codeception. Integrates Aerospike into Codeception tests.

Maintainers

👁 davert

Package info

github.com/Codeception/Aerospike-module

Homepage

pkg:composer/codeception/aerospike-module

Statistics

Installs: 45 789

Dependents: 4

Suggesters: 0

Stars: 3

Open Issues: 0

v1.0.3 2019-07-25 16:10 UTC

Requires

Requires (Dev)

None

Suggests

None

Provides

None

Conflicts

None

Replaces

None

MIT 2c13bd3f981ecfa7486855546e3bfdea414bc5d6

  • Michael Bodnarchuk <davert.woop@codeception.com>
  • Serghei Iakovlev <serghei.woop@codeception.com>

nosqltestingcodeceptionaerospike

This package is auto-updated.

Last update: 2026-06-28 07:07:38 UTC


README

Integrates Aerospike into Codeception tests.

Get Started

Requirements

To use this module on your machine, you need at least:

Installation

Create the composer.json file as follows:

{
 "require-dev": {
 "codeception/codeception": "^2.2",
 "codeception/aerospike-module": "^1.0"
 }
}

Then install dependencies:

$ php composer.phar install

Example (unit.suite.yml)

modules:
 - Aerospike:
 addr: '127.0.0.1' # Aerospike host to connect
 port: 3000 # default Aerospike port
 set: 'cache' # the Aerospike set to store data
 namespace: 'test' # the Aerospike namespace to store data
 reconnect: false # whether the module should reconnect to the Aerospike before each test
 prefix: 'prefix_' # the key prefix

Then regenerate base class for unit suite

$ vendor/bin/codecept build

Usage

Grabs value from Aerospike by key:

$users_count = $I->grabValueFromAerospike('users_count');

Checks item in Aerospike exists and the same as expected:

$I->seeInAerospike('key');
$I->seeInAerospike('key', 'value');

Checks item in Aerospike does not exist or is the same as expected:

$I->dontSeeInAerospike('key');
$I->dontSeeInAerospike('key', 'value');

Inserts data into Aerospike database:

$I->haveInAerospike('users', ['name' => 'miles', 'email' => 'miles@davis.com']);

Changelog

Changelog

License

Aerospike Module is open-sourced software licensed under the MIT License.

© 2015-2022 Codeception Team and contributors