Utility functions for testing Project Helix
condit
is a "conditional it
" that can be used in Mocha tests to specify conditions that need to be met to run the test. It is being used for integration tests that depend on the presence of environment variables.
const condit = require('@adobe/helix-testutils'); // add to your devDependencies
condit('This is an integration test', condit.hasenv('AUTH_TOKEN'), () => {
// do your testing here
});
npm install
npm test
npm run lint