def test_default_tag(self):
     """Ensure the default tag exists on gcr.io."""
     args = kubernetes_e2e.parse_args()
     match = re.match('gcr.io/([^:]+):(.+)', kubernetes_e2e.kubekins(args.tag))
     self.assertIsNotNone(match)
     url = 'https://gcr.io/v2/%s/manifests/%s' % (match.group(1),
                                                  match.group(2))
     data = json.loads(urllib.urlopen(url).read())
     self.assertNotIn('errors', data)
     self.assertIn('name', data)
 def test_default_tag(self):
     """Ensure the default tag exists on gcr.io."""
     args = self.parser.parse_args()
     match = re.match('gcr.io/([^:]+):(.+)', kubernetes_e2e.kubekins(args.tag))
     self.assertIsNotNone(match)
     url = 'https://gcr.io/v2/%s/manifests/%s' % (match.group(1),
                                                  match.group(2))
     data = json.loads(urllib.urlopen(url).read())
     self.assertNotIn('errors', data)
     self.assertIn('name', data)
Esempio n. 3
0
 def test_default_tag(self):
     """Ensure the default tag exists on gcr.io."""
     args = kubernetes_e2e.parse_args()
     match = re.match('gcr.io/([^:]+):(.+)', kubernetes_e2e.kubekins(args.tag))
     self.assertIsNotNone(match)
     url = 'https://gcr.io/v2/%s/manifests/%s' % (match.group(1),
                                                  match.group(2))
     req = urllib2.Request(url)
     req.add_header('Accept', 'application/vnd.docker.distribution.manifest.v2+json')
     data = json.loads(urllib2.urlopen(req).read())
     self.assertNotIn('errors', data)
     self.assertIn('config', data)
     self.assertIn('digest', data.get('config'))
Esempio n. 4
0
 def test_default_tag(self):
     """Ensure the default tag exists on gcr.io."""
     args = kubernetes_e2e.parse_args()
     match = re.match('gcr.io/([^:]+):(.+)', kubernetes_e2e.kubekins(args.tag))
     self.assertIsNotNone(match)
     url = 'https://gcr.io/v2/%s/manifests/%s' % (match.group(1),
                                                  match.group(2))
     req = urllib2.Request(url)
     req.add_header('Accept', 'application/vnd.docker.distribution.manifest.v2+json')
     data = json.loads(urllib2.urlopen(req).read())
     self.assertNotIn('errors', data)
     self.assertIn('config', data)
     self.assertIn('digest', data.get('config'))