Live Chat ~ Testing Walkthrough - uchicago-cs/chigame GitHub Wiki

This page provides an example and walkthrough for testing the live chat features of Chigame. Since these features are newly introduced and involve creating various tables and relationships, we felt that a detailed guide would be beneficial.

Walkthrough 📖

  1. Create a Superuser

python manage.py createsuperuser

We will use this account to access the /admin routes.

  1. Run chigame

python manage.py runserver

  1. Navigate to /admin and login with the new Superuser you created

image

  1. Create a new user

image

image

Once the message below is seen we are good to go:

image

Also add a username so we can find the user later:

image

  1. Verify/confirm that user's email (without truly doing so)

Click on "Add" and make sure to tick "Verified" when creating this record:

image

image

The email we use must be the same as the email used for our user.

We must also select the user:

image

image

image

  1. Create a chat and add the user to that chat

First, add the chat:

image

image

Now, get the ID of that chat:

image

image

The URL should be something like this: http://localhost:8000/admin/chat/livechat/2/change/

The number in the URL is our chat ID, keep note of this, as later we will be using it.

Then, add the user we created to the chat:

image

image

  1. Finally, navigate to chat/{ID} (replacing {ID} with the ID we took note of earlier, in our case: 2)

image

  1. Send a message to test that it works

image