def test_sample_unicode(self): '''This tests that the unicode representation of an :class:`~experiments.models.Sample` is set as its description.''' test_sample = Sample(description="Test Sample", type="tissue", species="mouse") test_sample.save() self.assertEqual(test_sample.__unicode__(), "Test Sample")
def test_created_new_sample_minimal(self): '''This test that a :class:`~experiments.models.Sample` can be created.''' test_sample = Sample(description="Test Sample", type="tissue", species="mouse") test_sample.save() self.assertEqual(test_sample.pk, 1) #presumes no genes loaded in fixture data
def test_sample_unicode(self): '''This tests that the unicode representation of an :class:`~experiments.models.Sample` is set as its description.''' test_sample = Sample(description = "Test Sample", type="tissue", species="mouse") test_sample.save() self.assertEqual(test_sample.__unicode__(), "Test Sample")
def test_created_new_sample_minimal(self): '''This test that a :class:`~experiments.models.Sample` can be created.''' test_sample = Sample(description = "Test Sample", type="tissue", species="mouse") test_sample.save() self.assertEqual(test_sample.pk, 1) #presumes no genes loaded in fixture data