Skip to content

admatic-tool/es-test-helper

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

2 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

const Factory = require("es-test-helper")

const config = {
  connection: {
    host: "http://localhost:9200"
  },
  indices: [
    {
      prefix: "offers-", 
      dayClusterFormat: "YYYY-MM-DD",
      mapping: {

      },
    },
    // wihtout cluster
    {
      name: "not_clustered",
      mapping: {
        
      },
    },
    // custom method
    {
      name: () => "abc" + "123",
      mapping: {
        
      },
    }

  ]
}


const EsTestHelper = Factory(config)


EsTestHelper.createIndices()
// create all elasticsearch indices

EsTestHelper.dropAll()
// drop all elasticsearch indices

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published