mirror of
https://github.com/discourse/discourse.git
synced 2024-11-26 01:13:38 +08:00
DEV: Fix basic auth in smoke test
This commit is contained in:
parent
e4718f1910
commit
decbc9194d
|
@ -80,10 +80,9 @@ const path = require("path");
|
|||
|
||||
if (process.env.AUTH_USER && process.env.AUTH_PASSWORD) {
|
||||
await exec("basic authentication", () => {
|
||||
return page.setExtraHTTPHeaders({
|
||||
Authorization: `Basic ${new Buffer(
|
||||
`${process.env.AUTH_USER}:${process.env.AUTH_PASSWORD}`
|
||||
).toString("base64")}`
|
||||
return page.authenticate({
|
||||
username: process.env.AUTH_USER,
|
||||
password: process.env.AUTH_PASSWORD
|
||||
});
|
||||
});
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue
Block a user