Beispiel #1
0
 def run_test(self, test_id, request):
     """Run diagnostics on this device."""
     GsxAccount.default(request.user)
     diags = diagnostics.Diagnostics(self.sn)
     diags.shipTo = request.user.location.gsx_shipto
     diags.diagnosticSuiteId = test_id
     return diags.run_test()
Beispiel #2
0
 def setUp(self):
     connect(os.getenv('GSX_USER'), os.getenv('GSX_SOLDTO'),
             os.getenv('GSX_ENV'))
     self.sn = os.getenv('GSX_SN')
     device = Product(sn=self.sn)
     self.diag = diagnostics.Diagnostics(serialNumber=self.sn)
     self.diag.shipTo = os.getenv('GSX_SHIPTO')
     suites = self.diag.fetch_suites()
     self.suite = suites[0]
Beispiel #3
0
 def setUp(self):
     super(TestRepairDiagnostics, self).setUp()
     self.results = diagnostics.Diagnostics(
         serialNumber=os.getenv('GSX_SN')).fetch()
Beispiel #4
0
 def fetch_tests(self, request):
     """Return applicable test suites."""
     GsxAccount.default(request.user)
     diags = diagnostics.Diagnostics(self.sn)
     diags.shipTo = request.user.location.gsx_shipto
     return diags.fetch_suites()