Skip to content

Commit

Permalink
Más arreglos
Browse files Browse the repository at this point in the history
  • Loading branch information
CANCI0 committed Apr 26, 2024
1 parent ab5ebfd commit aa212f5
Show file tree
Hide file tree
Showing 3 changed files with 21 additions and 4 deletions.
17 changes: 17 additions & 0 deletions webapp/e2e/steps/create-group.steps.js
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,23 @@ const feature = loadFeature("./features/create-group.feature");
let page;
let browser;

function generateUUID() {
const hexDigits = '0123456789abcdef';
let uuid = '';
for (let i = 0; i < 36; i++) {
if (i === 8 || i === 13 || i === 18 || i === 23) {
uuid += '-';
} else if (i === 14) {
uuid += '4';
} else if (i === 19) {
uuid += hexDigits.charAt(Math.floor(Math.random() * 4) + 8);
} else {
uuid += hexDigits.charAt(Math.floor(Math.random() * 16));
}
}
return uuid;
}

defineFeature(feature, (test) => {
beforeAll(async () => {
browser = process.env.GITHUB_ACTIONS
Expand Down
4 changes: 2 additions & 2 deletions webapp/e2e/steps/login-form.steps.js
Original file line number Diff line number Diff line change
Expand Up @@ -70,8 +70,8 @@ defineFeature(feature, (test) => {
});

test("The user is registered in the site", ({ given, when, then }) => {
let username;
let password;
var username;
var password;

given("A registered user", async () => {
username = "testuser";
Expand Down
4 changes: 2 additions & 2 deletions webapp/e2e/steps/register-form.steps.js
Original file line number Diff line number Diff line change
Expand Up @@ -87,8 +87,8 @@ defineFeature(feature, (test) => {
});

test("The user is not registered in the site", ({ given, when, then }) => {
let username;
let password;
var username;
var password;

given("An unregistered user", async () => {
await expect(page).toClick("a", { text: "Regístrate" });
Expand Down

0 comments on commit aa212f5

Please sign in to comment.