Skip to content

Commit

Permalink
improve code & comments
Browse files Browse the repository at this point in the history
  • Loading branch information
Fabien Coelho committed May 23, 2024
1 parent a047aad commit 2898618
Showing 1 changed file with 5 additions and 3 deletions.
8 changes: 5 additions & 3 deletions tests/secret.py
Original file line number Diff line number Diff line change
Expand Up @@ -8,12 +8,14 @@
random.seed(os.environ.get("TEST_SEED", None))

# parameters
LENGTH: int = 16
CHARS: str = string.printable.replace(",", "") # all but ","
PASS_LENGTH: int = 16
PASS_CHARS: str = string.printable.replace(",", "") # all but ","

# user logins to generate
USERS: list[str] = ["calvin", "hobbes", "susie", "moe"]

# login -> clear-password
PASSES: dict[str, str] = {
login: "".join(random.choice(CHARS) for _ in range(LENGTH))
login: "".join(random.choice(PASS_CHARS) for _ in range(PASS_LENGTH))
for login in USERS
}

0 comments on commit 2898618

Please sign in to comment.