Esempio n. 1
0
class Feature(db.Model):
    __tablename__ = "feature"
    id = db.Column(db.Integer, primary_key=True)
    name = db.Column(db.String(100))

    def __init__(self, name, description):
        self.name = name

    def __repr__(self):
        return '<User %r>' % self.name
Esempio n. 2
0
class Result(db.Model):
    __tablename__ = "result"
    id = db.Column(db.Integer, primary_key=True)
    #packageID = db.Column(db.Integer)
    total = db.Column(db.Integer)
    passes = db.Column("pass", db.Integer)
    fail = db.Column(db.Integer)
    error = db.Column(db.Integer)
    executed = db.Column(db.Date())
    packageID = db.Column(db.Integer, db.ForeignKey('package.id'))
    status = db.Column(db.String(100))
    package = db.relationship('Package',
                              backref=db.backref('result', lazy='dynamic'))
    duration = db.Column(db.String(100))

    def __init__(self, packageID, total, passes, fail, executed, status, error,
                 duration):
        self.packageID = packageID
        self.total = total
        self.executed = executed
        self.passes = passes
        self.fail = fail
        self.status = status
        self.error = error
        self.duration = duration
Esempio n. 3
0
class Package(db.Model):
    __tablename__ = "package"
    id = db.Column(db.Integer, primary_key=True)
    name = db.Column(db.String(100))
    description = db.Column(db.String(100))
    configID = db.Column(db.Integer)

    def __init__(self, name, description, configID):
        self.name = name
        self.description = description
        self.configID = configID

    def __repr__(self):
        return '<User %r>' % self.name
Esempio n. 4
0
class PackageSuite(db.Model):
    __tablename__ = "packagesuite"

    id = db.Column(db.Integer, primary_key=True)
    packageID = db.Column(db.Integer, db.ForeignKey('package.id'))
    package = db.relationship('Package',
                              backref=db.backref('packagesuite',
                                                 lazy='dynamic'))
    featureID = db.Column(db.Integer)
    testcaseID = db.Column(db.Integer)

    def __init__(self, package, featureID, testcaseID):
        self.package = package
        self.featureID = featureID
        self.testcaseID = testcaseID
Esempio n. 5
0
class ResultSuite(db.Model):
    __tablename__ = "resultsuite"
    id = db.Column(db.Integer, primary_key=True)

    executed = db.Column(db.Date())
    testcaseID = db.Column(db.String(100))
    status = db.Column(db.Integer)
    executed = db.Column(db.DateTime, default=datetime.now())
    log = db.Column(db.String(500))
    packageID = db.Column(db.Integer, db.ForeignKey('package.id'))
    package = db.relationship('Package',
                              backref=db.backref('resultsuite',
                                                 lazy='dynamic'))

    resultID = db.Column(db.Integer, db.ForeignKey('result.id'))
    result = db.relationship('Result',
                             backref=db.backref('resultsuite', lazy='dynamic'))

    def __init__(self, resultID, packageID, testcaseID, status, log):
        self.packageID = packageID
        self.testcaseID = testcaseID
        self.resultID = resultID
        self.status = status
        self.log = log
Esempio n. 6
0
class Config(db.Model):
    __tablename__ = "config"
    id = db.Column(db.Integer, primary_key=True)
    name = db.Column(db.String(100))    
    mnrIP = db.Column(db.String(100))
    pcfIP = db.Column(db.String(100))
    instIP = db.Column(db.String(100))
    opsDirectorUsername = db.Column(db.String(100))
    opsDirectorPassword = db.Column(db.String(100))
    opsDirectorIP = db.Column(db.String(100))
    appsManagerUser = db.Column(db.String(100))
    appsManagerPassword = db.Column(db.String(100))
    appsDomain = db.Column(db.String(100))
    privateKey = db.Column(db.String(300))
    pcfUsername = db.Column(db.String(300))
    pcfPassword = db.Column(db.String(300))
    vcenterIP = db.Column(db.String(300))
    vcenterUsername = db.Column(db.String(300))
    vcenterPassword = db.Column(db.String(300))
    
 
    def __init__(self, mnrip, instip, name, pcfIP, opsDirectorIP, opsDirectorUsername, opsDirectorPassword, appsManagerUser, appsManagerPassword , appsDomain, privateKey, pcfuname, pcfpass, vIP, vUsername, vPassword):
        self.mnrIP = mnrip
        self.instIP = instip
        self.name = name
        self.pcfIP = pcfIP
        self.opsDirectorIP = opsDirectorIP
        self.opsDirectorUsername = opsDirectorUsername
        self.opsDirectorPassword = opsDirectorPassword
        self.appsManagerUser = appsManagerUser
        self.appsManagerPassword = appsManagerPassword
        self.appsDomain = appsDomain
        self.privateKey = privateKey
        self.pcfUsername = pcfuname
        self.pcfPassword = pcfpass
        self.vcenterIP = vIP
        self.vcenterUsername = vUsername
        self.vcenterPassword = vPassword