mirror of
https://github.com/discourse/discourse.git
synced 2024-11-24 00:37:06 +08:00
Allow username and password to be passed via ENV for smoke test.
This commit is contained in:
parent
80435cf2af
commit
f4cc71d643
|
@ -110,7 +110,7 @@ function run() {
|
|||
});
|
||||
} else if (action.exec) {
|
||||
console.log("EXEC: " + action.desc);
|
||||
page.evaluate(action.exec);
|
||||
page.evaluate(action.exec, system);
|
||||
performNextAction();
|
||||
} else if (action.execAsync) {
|
||||
console.log("EXEC ASYNC: " + action.desc + " - " + action.delay + "ms");
|
||||
|
@ -186,9 +186,9 @@ var runTests = function() {
|
|||
return $(".login-modal").length;
|
||||
});
|
||||
|
||||
exec("type in credentials & log in", function() {
|
||||
$("#login-account-name").val("smoke_user").trigger("change");
|
||||
$("#login-account-password").val("P4ssw0rd").trigger("change");
|
||||
exec("type in credentials & log in", function(system) {
|
||||
$("#login-account-name").val(system.env['DISCOURSE_USERNAME'] || 'smoke_user').trigger("change");
|
||||
$("#login-account-password").val(system.env["DISCOURSE_PASSWORD"] || 'P4ssw0rd').trigger("change");
|
||||
$(".login-modal .btn-primary").click();
|
||||
});
|
||||
|
||||
|
|
Loading…
Reference in New Issue
Block a user