Exemplo n.º 1
0
    def test_mocking_works(self):

        document = DocumentFactory()
        document.file = self.file_mock
        document.full_clean()
        document.save()
Exemplo n.º 2
0
    def test_can_access_full_path_once_created(self):
        doc = DocumentFactory()

        file_path = doc.get_absolute_path()

        self.assertTrue(os.path.exists(file_path))