# Generated by Django 3.0.6 on 2020-06-01 14:35

from django.conf import settings
from django.db import migrations, models
import django.db.models.deletion


class Migration(migrations.Migration):

    dependencies = [
        migrations.swappable_dependency(settings.AUTH_USER_MODEL),
        ('apitest', '0004_apirunrecord'),
    ]

    operations = [
        migrations.CreateModel(
            name='Case',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('name', models.CharField(max_length=50, verbose_name='ケース名')),
                ('description', models.CharField(blank=True, max_length=1024, null=True, verbose_name='詳細')),
                ('create_time', models.DateTimeField(auto_now=True, verbose_name='更新時間')),
                ('api_list', models.ManyToManyField(related_name='case_list', to='apitest.Api')),
                ('project', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, related_name='case_list', to='apitest.Project', verbose_name='所属プロジェクト')),
                ('user', models.ForeignKey(blank=True, null=True, on_delete=django.db.models.deletion.SET_NULL, to=settings.AUTH_USER_MODEL, verbose_name='制作者')),
            ],
        ),
        migrations.CreateModel(
            name='CaseArgument',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('name', models.CharField(max_length=100, verbose_name='パラメータ名')),
                ('value', models.CharField(max_length=100, verbose_name='パラメータ値')),
                ('case', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, related_name='arguments', to='apitest.Case', verbose_name='テストケース')),
            ],
        ),
        migrations.CreateModel(
            name='ApiArgument',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('name', models.CharField(max_length=100, verbose_name='パラメータ名')),
                ('origin', models.CharField(choices=[('HEADER', 'HEADER'), ('BODY', 'BODY'), ('COOKIE', 'COOKIE')], max_length=20, verbose_name='パラメータ出所')),
                ('format', models.CharField(max_length=100, verbose_name='パラメータ取得形式')),
                ('api', models.ForeignKey(null=True, on_delete=django.db.models.deletion.CASCADE, related_name='arguments', to='apitest.Api', verbose_name='ケースAPI')),
            ],
        ),
    ]
