This is a
playground to test code. It runs a full
Node.js environment and already has all of
npm’s 1,000,000+ packages pre-installed, including
mecano with all
npm packages installed. Try it out:
This service is provided by RunKit and is not affiliated with npm, Inc or the package authors.
Mecano gather a set of functions usually used during system deployment. Documentation is available on the project website.
Functions include "chmod", "chown", "copy", "download", "execute", "extract", "git", "ini", "krb5_ktadd", "krb5_addprinc", "krb5_delprinc", "ldap_acl", "ldap_index", "ldap_schema", "link", "mkdir", "move", "remove", "render", "service", "touch", "upload" and "file". They all share common usages and philosophies:
npm install mecano
For the tests to execute successfully, you must:
ssh $(whoami)@localhost) without a password
# run all tests npm test # or a subset npm run coffee && mocha test/api
Some of the tests require a specific environment. You are encouraged to customize which tests you wish to run and to use docker container.
To filter and configure your tests, you can either create a "test.coffee" at the root of this project or point the "MECANO_TEST" environment variable to such a file. You can use the file "test.coffee.sample" as a starting point.
There are tests prepared to run on CentOS and Ubuntu using docker. Goto to one of the docker directory and run docker-compose, here's an example to run tests on CentOS:
cd docker/centos7 # or centos6 # Run all tests docker-compose up --abort-on-container-exit # Enter bash console docker-compose run --rm nodejs # Run a subset of the tests docker-compose run --rm nodejs test/core