Skip to content

Commit

Permalink
Refactoring DiagramTest
Browse files Browse the repository at this point in the history
  • Loading branch information
victorette committed May 27, 2014
1 parent c292654 commit 2059b13
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion src/dbDesigner/test/ProtoDiagramTest.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
from django.http import HttpRequest
from dbDesigner.protoDiagram import getEntitiesJSONDiagram, synchDiagramFromDB, getElementsDiagramFromSelectedTables, synchDBFromDiagram, getDefaultDiagram
from dbDesigner.protoDiagramEntity import listDiagrams, openDiagram, createDiagram, saveDiagram, deleteDiagram
from prototype.testprototype.testmodels.TestUtilities import createTestDiagram, createTestEntity
from prototype.testprototype.testmodels.TestUtilities import createTestDiagram, createTestEntity, createTestRelationship
from requests import Request
from django.contrib.auth import authenticate
import json, uuid, unicodedata
Expand Down Expand Up @@ -81,10 +81,13 @@ def setUp(self):
self.basic_request = CreateBasicRequest()
self.prepped_request = CreatePreparedRequest()
self.auth_request = CreatePreparedAuthRequest()

self.testRelationShip = createTestRelationship()

def tearDown(self):
self.entity.delete()
self.diagram.delete()
self.testRelationShip.delete()

def test_getEntitiesJSONDiagram_thenReturnEntity(self):
response = json.loads(getEntitiesJSONDiagram(self.basic_request).content)
Expand Down

0 comments on commit 2059b13

Please sign in to comment.