Version initiale de test

This commit is contained in:
2017-08-16 22:00:41 +02:00
commit 5deacda00b
15 changed files with 344 additions and 0 deletions

View File

View File

@ -0,0 +1,5 @@
from django.contrib import admin
from games.models import Console
admin.site.register(Console)

5
collection/games/apps.py Normal file
View File

@ -0,0 +1,5 @@
from django.apps import AppConfig
class GamesConfig(AppConfig):
name = 'games'

View File

@ -0,0 +1,23 @@
# -*- coding: utf-8 -*-
# Generated by Django 1.11 on 2017-08-16 19:55
from __future__ import unicode_literals
from django.db import migrations, models
class Migration(migrations.Migration):
initial = True
dependencies = [
]
operations = [
migrations.CreateModel(
name='Console',
fields=[
('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
('name', models.CharField(max_length=254)),
],
),
]

View File

View File

@ -0,0 +1,11 @@
from django.db import models
class Console(models.Model):
"""
All console, system or box that can be used to play video games.
"""
name = models.CharField(max_length=254)
def __str__(self):
return '%s' % self.name

View File

@ -0,0 +1,3 @@
from django.test import TestCase
# Create your tests here.

View File

@ -0,0 +1,3 @@
from django.shortcuts import render
# Create your views here.