Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: system.debug config field #756

Merged
merged 1 commit into from
Jul 11, 2023
Merged

Conversation

KuznetsovRoman
Copy link
Member

Что сделано

Починил system.debug в конфиге
Установил дефолтное значение LOG_LEVEL на "error"

Comment on lines 60 to 64
_setLogLevel() {
if (!process.env.WDIO_LOG_LEVEL) {
process.env.WDIO_LOG_LEVEL = _.get(this.config, "system.debug", false) ? "trace" : "error";
}
}
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

После загрузки конфига, устанавливаем переменную окружения WDIO_LOG_LEVEL основываясь на поле в конфиге, при этом если переменная среды уже установлена, не затираем ее

src/browser/new-browser.js Outdated Show resolved Hide resolved
test/src/browser/new-browser.js Outdated Show resolved Hide resolved
test/src/hermione.js Outdated Show resolved Hide resolved
[
{ debug: true, WDIO_LOG_LEVEL: "trace" },
{ debug: false, WDIO_LOG_LEVEL: "error" },
{ WDIO_LOG_LEVEL: "error" },
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

проверка logLevel по умолчанию

test/src/browser/new-browser.js Outdated Show resolved Hide resolved
test/src/hermione.js Outdated Show resolved Hide resolved
@KuznetsovRoman KuznetsovRoman force-pushed the HERMIONE-727.system_debug branch 4 times, most recently from 999e562 to 4a4f68e Compare April 11, 2023 13:07
@KuznetsovRoman KuznetsovRoman force-pushed the HERMIONE-727.system_debug branch 2 times, most recently from 30e3046 to cb37c08 Compare April 28, 2023 13:27
@KuznetsovRoman KuznetsovRoman force-pushed the HERMIONE-727.system_debug branch 2 times, most recently from 12604bb to e5cd031 Compare July 11, 2023 19:33
@KuznetsovRoman KuznetsovRoman merged commit e0e698f into master Jul 11, 2023
2 checks passed
@KuznetsovRoman KuznetsovRoman deleted the HERMIONE-727.system_debug branch July 11, 2023 19:57
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants