From b57fb83af900a26ce6fb6b4787a37c4b52675173 Mon Sep 17 00:00:00 2001 From: Kevin Morris Date: Sun, 24 Oct 2021 05:53:28 +0000 Subject: [PATCH] Update Testing Guide --- Testing-Guide.md | 66 ++++++++++++++++++++++++++++++++++++++---------- 1 file changed, 53 insertions(+), 13 deletions(-) diff --git a/Testing-Guide.md b/Testing-Guide.md index d04f5ea..372c305 100644 --- a/Testing-Guide.md +++ b/Testing-Guide.md @@ -31,7 +31,6 @@ If poetry is configured to create virtualenvs with `poetry config virtualenvs.create true --local` (recommended), users can install aurweb dependencies and the aurweb project into their poetry virtualenv: - $ poetry lock # Ensure that poetry dep resolution is up to date. $ poetry update # Update/fetch all dependencies in the virtualenv. $ poetry install # Install project-specific package and scripts. @@ -74,11 +73,12 @@ For a complete rundown on all of the services available, see the As a bit of a guide to the guide, I'd like to help you navigate around a bit: -1. Read [User Experience](#user-experience) -2. Read [Edge Cases](#edge-cases) -3. Read [Getting Started](#getting-started) +1. Read [Accounts](#accounts) +2. Read [User Experience](#user-experience) +3. Read [Edge Cases](#edge-cases) +4. Read [Getting Started](#getting-started) - Follow the link to [Development Servers](#development-servers) at the end -4. Go back and focus on [User Experience](#user-experience) or any of the +5. Go back and focus on [User Experience](#user-experience) or any of the other needs specified in [What We Need Tested](#what-we-need-tested) and [What Else?](#what-else) ## What We Need Tested @@ -181,14 +181,6 @@ as the mysql client does something other than reach the mariadb server with `localhost` (assumed some type of confusion with localhost, didn't look much further). -###### Add User - -**Note**: To use the script, you'll need a valid AUR_CONFIG to the -target database and aurweb Python dependencies (see [poetry](#poetry-python-dependencies)). - -You can create a user account in the database using the -[util/adduser.py](https://gitlab.archlinux.org/archlinux/aurweb/-/tree/pu/util/adduser.py) script. - ###### Generating Dummy Data @@ -264,6 +256,54 @@ by the Root CA certificate `ca.root.pem`. | [php-fpm](#php-fpm) | https://localhost:8443 | | [fastapi](#fastapi) | https://localhost:8444 | +## Accounts + +If you have not created or requested an account, users can login +to all users generated by `gendummydata.py` (most of the users on +aur-dev.archlinux.org) using a password which is exactly the same as +the account's username. + +Example: + + Username: some-generated-user + Password: some-generated-user + +Test users are completely free to change the password of a dummy +user, but this is highly discourages in favor of requesting an +account of your own (see below). + +#### aur-dev.archlinux.org Accounts + +`aur-dev.archlinux.org` does not expose its database to users. For this +reason, we don't allow users to freely create accounts on their own. + +For users testing Trusted User or Developer-specific routes, requests +for a Trusted User account can be made to aur-dev@lists.archlinux.org. + +Send an email to aur-dev@lists.archlinux.org titled +`[Test Account Request] your_username` with details about which account type +you would like the account to have. + +Upon receiving account requests, DevOps will be able to generate +an account for you in `aur-dev.archlinux.org`'s database, as long +as there is no existing email/username conflict. + +#### Local Docker Accounts + +Users who take advantage of a local Docker instance for testing have full +access to the Docker database and can use the [adduser.py](#add-user) script +described below. + +###### Add User + +**Note**: To use the script, you'll need a valid AUR_CONFIG to the +target database and aurweb Python dependencies (see [poetry](#poetry-python-dependencies)). +Users can also `docker exec python /aurweb/util/adduser.py ...` from a +Docker host if you wish to avoid installing poetry dependencies. + +You can create a user account in the database using the +[util/adduser.py](https://gitlab.archlinux.org/archlinux/aurweb/-/tree/pu/util/adduser.py) script. + ## User Experience Some of the most important testing we could do for aurweb at this