Created
February 19, 2019 07:55
-
-
Save kelvinndmo/eda8f2cbc9cfe2500d14e7df448262d1 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from django.test import TestCase | |
from sendy.models import Parcel | |
# Create your tests here. | |
class TestParcel(TestCase): | |
def setUp(self): | |
self.parcel = Parcels(sender="Kelvin onkundi", email="[email protected]", Recipient="Swaleh", recepient_contact="07999999") | |
self.parcel.save() | |
def test_create_parcel(self): | |
self.assertEqual(self.parcel.sender, "Kelvin Onkundi") | |
def test_parcel_list(self): | |
self.assertEqual(Parcel.objects.count(),1) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment