chore(curriculum): add domain variety to email masking visible tests (#61069)

This commit is contained in:
Giftea ☕
2025-06-27 18:08:02 +01:00
committed by GitHub
parent fefbfd7c58
commit 97c4f45dd5
@@ -21,6 +21,8 @@ Fulfill the user stories below and get all the tests to pass to complete the lab
4. Call the `maskEmail` function with the `email` variable and output the result to the console.
5. `maskEmail("apple.pie@example.com")` should return `"a*******e@example.com"`.
6. `maskEmail("freecodecamp@example.com")` should return `"f**********p@example.com"`.
7. `maskEmail("info@test.dev")` should return `"i**o@test.dev"`.
8. `maskEmail("user@domain.org")` should return `"u**r@domain.org"`.
# --hints--
@@ -60,6 +62,18 @@ assert.strictEqual(maskEmail("apple.pie@example.com"),"a*******e@example.com");
assert.strictEqual(maskEmail("freecodecamp@example.com"), "f**********p@example.com");
```
`maskEmail("info@test.dev")` should return `"i**o@test.dev"`.
```js
assert.strictEqual(maskEmail("info@test.dev"), "i**o@test.dev");
```
`maskEmail("user@domain.org")` should return `"u**r@domain.org"`.
```js
assert.strictEqual(maskEmail("user@domain.org"), "u**r@domain.org");
```
Your `maskEmail` should produce the correct result.
```js