|
|
@ -7,7 +7,7 @@ def get_entity_object(job, name, args): |
|
|
|
|
|
|
|
if name in [B.SUBJECT_STEPS, B.SUBJECT_STEP]: |
|
|
|
entity = getStep(job) |
|
|
|
elif name in [B.SUBJECT_STORIES, B.SUBJECT_STORY]: |
|
|
|
elif name in [B.SUBJECT_STORIES, B.SUBJECT_STORY, "storys"]: |
|
|
|
entity = getStory(job) |
|
|
|
elif name in [B.SUBJECT_VARIANTS, B.SUBJECT_VARIANT]: |
|
|
|
entity = getVariant(job) |
|
|
@ -21,24 +21,38 @@ def get_entity_object(job, name, args): |
|
|
|
entity = getApplication(job) |
|
|
|
elif name in [B.SUBJECT_COMPS, B.SUBJECT_COMP]: |
|
|
|
entity = getComponent(job) |
|
|
|
elif name in [B.SUBJECT_ARTIFACTS, B.SUBJECT_ARTIFACT]: |
|
|
|
entity = getEnvironment(job) |
|
|
|
elif name in [B.SUBJECT_TESTCASES, B.SUBJECT_TESTCASE]: |
|
|
|
entity = getTestcase(job) |
|
|
|
elif name in [B.SUBJECT_TESTSUITES]: |
|
|
|
elif name in [B.SUBJECT_TESTSUITES, B.SUBJECT_TESTSUITE]: |
|
|
|
entity = getTestsuite(job) |
|
|
|
elif name in [B.SUBJECT_TESTPLANS, B.SUBJECT_TESTPLAN]: |
|
|
|
entity = getTestplan(job) |
|
|
|
elif name in [B.SUBJECT_USERS, B.SUBJECT_USER]: |
|
|
|
entity = getUser(job) |
|
|
|
elif name in [B.SUBJECT_REL, B.SUBJECT_RELS]: |
|
|
|
entity = getRelease(job) |
|
|
|
elif name in [B.SUBJECT_ENVIRONMENT, B.SUBJECT_ENVIRONMENTS]: |
|
|
|
entity = getEnvironment(job) |
|
|
|
else: |
|
|
|
return None |
|
|
|
entity.setAttributes(job, args, name, entity.getFieldList(), entity.getNodeList(), entity.getSubtableList()) |
|
|
|
#testserver = basic.Testserver.getInstance(job) |
|
|
|
return entity |
|
|
|
|
|
|
|
def getEnvironment(job=None): |
|
|
|
def getRelease(job=None, name=""): |
|
|
|
import model.release |
|
|
|
return model.release.Release(job) |
|
|
|
|
|
|
|
def getEnvironment(job=None, name=""): |
|
|
|
import model.environment |
|
|
|
return model.environment.Environment(job) |
|
|
|
|
|
|
|
def getArtifact(job=None, name=""): |
|
|
|
import model.artifact |
|
|
|
return model.artifact.Artifact(job) |
|
|
|
|
|
|
|
def getApplication(job=None, args={}, name=""): |
|
|
|
import model.application |
|
|
|
return model.application.Application(job) |
|
|
|