Skip to content

Commit

Permalink
Merge branch '3.x' into glob-backward-compitibilty
Browse files Browse the repository at this point in the history
  • Loading branch information
kobenguyent authored Jan 29, 2025
2 parents f867d59 + 236dc72 commit a63e07e
Show file tree
Hide file tree
Showing 26 changed files with 678 additions and 402 deletions.
10 changes: 5 additions & 5 deletions lib/container.js
Original file line number Diff line number Diff line change
Expand Up @@ -162,18 +162,18 @@ class Container {
* @param {Object<string, *>} newSupport
* @param {Object<string, *>} newPlugins
*/
static clear(newHelpers, newSupport, newPlugins) {
container.helpers = newHelpers || {}
static clear(newHelpers = {}, newSupport = {}, newPlugins = {}) {
container.helpers = newHelpers
container.translation = loadTranslation()
container.proxySupport = createSupportObjects(newSupport || {})
container.plugins = newPlugins || {}
container.proxySupport = createSupportObjects(newSupport)
container.plugins = newPlugins
asyncHelperPromise = Promise.resolve()
store.actor = null
debug('container cleared')
}

/**
* @param {Function} fn
* @param {Function|null} fn
* @returns {Promise<void>}
*/
static async started(fn = null) {
Expand Down
2 changes: 1 addition & 1 deletion lib/mocha/gherkin.js
Original file line number Diff line number Diff line change
Expand Up @@ -107,7 +107,7 @@ module.exports = (text, file) => {
)
continue
}
if (child.scenario && (currentLanguage ? child.scenario.keyword === currentLanguage.contexts.ScenarioOutline : child.scenario.keyword === 'Scenario Outline')) {
if (child.scenario && (currentLanguage ? currentLanguage.contexts.ScenarioOutline.includes(child.scenario.keyword) : child.scenario.keyword === 'Scenario Outline')) {
for (const examples of child.scenario.examples) {
const fields = examples.tableHeader.cells.map(c => c.value)
for (const example of examples.tableBody) {
Expand Down
Loading

0 comments on commit a63e07e

Please sign in to comment.