0.0.2 • Published 1 year ago

@codeceptjs-bootstraps/core v0.0.2

Weekly downloads
-
License
MIT
Repository
github
Last release
1 year ago

@codeceptjs-bootstraps/core Made in Ukraine

This package contains core functionality for managing the CodeceptJS bootstraps.

Installation

npm add -D @codeceptjs-bootstraps/core
yarn add -D @codeceptjs-bootstraps/core

createPipeline

import { createPipeline } from '@codeceptjs-bootstraps/core'

const firstBootstrap = {
  bootstrap: () => {
    console.log('bootstrap 1')
  },
  teardown: async () => {
    console.log('teardown 1')
  },
}

const secondBootstrap = {
  bootstrap: async () => {
    console.log('bootstrap 2')
  },
  bootstrapAll: () => {
    console.log('bootstrapAll 2')
  },
}

const pipeline = createPipeline([
  firstBootstrap,
  secondBootstrap,
])

exports.config = {
  ...pipeline
}
/*
Expected output:
1) bootstrapAll 2
2) bootstrap 1
3) bootstrap 2
4) teardown 1
*/
0.0.2

1 year ago