refactor(Cypress): add nodemodules

This commit is contained in:
2021-09-02 17:18:41 +02:00
parent 1aa57bbd0a
commit bc6e1bc12e
4238 changed files with 340975 additions and 8 deletions

38
node_modules/dash-ast/test/index.js generated vendored Normal file
View File

@@ -0,0 +1,38 @@
var test = require('tape')
var src = require('fs').readFileSync(require.resolve('acorn'))
var parse = require('acorn').parse
var dash = require('../')
var NUM_NODES = 25426
test('dash-ast', function (t) {
var ast = parse(src)
var i = 0
dash(ast, function (node) { i++ })
t.equal(i, NUM_NODES)
t.comment('walked ' + i + ' nodes')
t.end()
})
test('dash-ast with .parent', function (t) {
var ast = parse(src)
var i = 0
dash.withParent(ast, function (node) { i++ })
t.equal(i, NUM_NODES)
t.comment('walked ' + i + ' nodes')
t.end()
})
test('dash-ast with enter/leave', function (t) {
var ast = parse(src)
var i = 0
var j = 0
dash(ast, {
enter: function (node) { i++ },
leave: function (node) { j++ }
})
t.equal(i, NUM_NODES)
t.equal(j, NUM_NODES)
t.comment('walked ' + [i, j] + ' nodes')
t.end()
})