testing-crud-login-drf

Creation of an application in django on music albums

Before

Before you must verify that you have the latest python version downloaded

Start

In your terminal
first create a virtual environment

python -m venv env

In windows

env\Scripts\activate.bat

In Unix o MacOS run

source env\Scripts\activate.bat

Run the command

pip install -r requirements.txt

Create an .env file in the same location as the manage.py file

inside the .env file

  - DJANGO_SETTINGS_MODULE = 'app.settings'
  - DB_ENGINE = 'django.db.backends.postgresql'
  - DB_NAME = DATABASE NAME
  - DB_USER = NAME USER IN THE DATABASE
  - DB_PASSWORD = DATABASE PASSWORD
  - DB_HOST = '127.0.0.1'
  - DB_PORT = '5432'

After

Run the command to perform the migrations to the database

  python manage.py makemigrations core

then run the command

  python manage.py migrate

and then run the command

  python manage.py runserver

You can see the good practices that I do
running the command:

  python manage.py test

This is the page

Captura

Sign in, Sign up and authentication token

Get started by creating an account

1

2

Then login with login
3

4

Then authenticate

5

Add artist, gender, songs and album

Add gender

6.

Get gender

7

Add artist

8

Get artist
9

Add song

10

Get song

11

Add album

12

Get album

13
14

Logout

It is very important to log out
you only need to do this.

15

then press logout

16

GitHub

View Github