Getting Parent in from test path in Mocha Node Js

I’m receiving an error ‘parent is not a function’
The code is as follows

Const path = require(‘path’)

Const takeScreenshot = function(page, test){
Const screen_path = path.normalize(path.join(‘./screenshot/‘, test.test.parent.title))
test.currentTitke

//take screenshot
}

This topic was automatically closed 91 days after the last reply. New replies are no longer allowed.