Fakultas Ilmu Komputer UI

Commit a148446c authored by Kefas Satrio Bangkit Solideantyo's avatar Kefas Satrio Bangkit Solideantyo
Browse files

[RED] membuat test_diet_profile_saved

parent 42af2448
Pipeline #64186 failed with stage
in 9 minutes and 56 seconds
from django.contrib import admin
# Register your models here.
from django.apps import AppConfig
class DietelaquizConfig(AppConfig):
name = 'DietelaQuiz'
from django.db import models
# Create your models here.
from django.test import TestCase, Client
from .models import DietProfile
# Create your tests here.
class DietelaQuiz(TestCase):
def setUp(self):
self.c = Client()
def test_diet_profile_saved(self):
nama="test", email="test@test.com", usia=20,
berat_badan=60, tinggi_badan=172, jenis_kelamin=2,
kondisi_khusus=1, aktif_badan=1, sayur_dimakan_sehari=1,
buah_dimakan_sehari=1, gorengan_dimakan_sehari=1, cemilan_manis_dimakan_sehari=1,
minuman_manis_diminum_sehari=1, makanan_kemasan_dimakan_sehari=1, makanan_besar_dimakan_sehari=1,
cemilan_dimakan_sehari=1, jenis_makanan_pagi=1, kondisi_saat_ini=1,
masalah_ingin_diselesaikan=1, masalah_kesehatan_dimiliki=1
self.assertEqual(DietProfile.objects.count(), 1)
from django.shortcuts import render
# Create your views here.
......@@ -48,7 +48,8 @@ INSTALLED_APPS = [
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment