Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
export async function exportCodeToFile(
selectedLanguages,
{ test, suite },
{ enableOriginTracing, beforeEachOptions }
) {
const project = UiState.project.toJS()
const { url, tests } = project
for (const language of selectedLanguages) {
let emittedCode
let options = {
url,
tests,
project,
enableOriginTracing,
beforeEachOptions: {
browserName: userAgent.browserName,
...beforeEachOptions,
},
}
options.test = test ? test : undefined
options.suite = suite
? projectProcessor.normalizeTestsInSuite({ suite, tests })
: undefined
if (vendorLanguages.hasOwnProperty(language)) {
const result = await PluginManager.emitMessage({
action: 'export',
entity: 'vendor',
language,
options,
})
emittedCode = result[0].response
} else if (test) {