{"action":"created","comment":{"url":"https://api.github.com/repos/projectatomic/atomicapp/pulls/comments/77323769","id":77323769,"diff_hunk":"@@ -0,0 +1,662 @@\n+import os\n+import logging\n+import logging.config\n+import re\n+import time\n+import anymarkup\n+import datetime\n+import unittest\n+import subprocess\n+from collections import OrderedDict\n+import tempfile\n+\n+from .providers import kubernetes\n+from .providers import openshift\n+\n+LOGGING_CONF = dict(\n+    version=1,\n+    formatters=dict(\n+        bare={\n+            \"datefmt\": \"%Y-%m-%d %H:%M:%S\",\n+            \"format\": \"[%(asctime)s][%(name)10s %(levelname)7s] %(message)s\"\n+        },\n+    ),\n+    handlers=dict(\n+        console={\n+            \"class\": \"logging.StreamHandler\",\n+            \"formatter\": \"bare\",\n+            \"level\": \"DEBUG\",\n+            \"stream\": \"ext://sys.stderr\",\n+        }\n+    ),\n+    loggers=dict(\n+        test={\n+            \"level\": \"DEBUG\",\n+            \"propagate\": False,\n+            \"handlers\": [\"console\"],\n+        }\n+    )\n+)\n+\n+logging.config.dictConfig(LOGGING_CONF)\n+logger = logging.getLogger('test')\n+\n+\n+class BaseProviderTestSuite(unittest.TestCase):\n+    \"\"\"\n+    Base test suite for a provider: docker, kubernetes, etc.\n+    \"\"\"\n+\n+    def setUp(self):\n+        self.get_initial_state()\n+\n+    def tearDown(self):\n+        self.restore_initial_state()\n+\n+    def get_initial_state(self):\n+        raise NotImplementedError\n+\n+    def restore_initial_state(self):\n+        raise NotImplementedError\n+\n+    def deploy(self, app_spec, answers):\n+        \"\"\"\n+        Deploy to provider\n+        \"\"\"\n+        raise NotImplementedError\n+\n+    def undeploy(self, app_spec, answers):\n+        \"\"\"\n+        Undeploy from provider\n+        \"\"\"\n+        raise NotImplementedError\n+\n+    def get_tmp_answers_file(self, answers):\n+        f = tempfile.NamedTemporaryFile(delete=False, suffix='.conf')\n+        f.close()\n+        anymarkup.serialize_file(answers, f.name, format='ini')\n+        return f.name\n+\n+    @property\n+    def nulecule_lib(self):\n+        return os.environ.get('NULECULE_LIB') or \\\n+            os.path.join(os.path.dirname(__file__), '../../../nulecule-library')","path":"tests/functional/base.py","position":83,"original_position":83,"commit_id":"836125e6356326457fa46c2dc230207c4bf60710","original_commit_id":"836125e6356326457fa46c2dc230207c4bf60710","user":{"login":"rtnpro","id":231684,"avatar_url":"https://avatars.githubusercontent.com/u/231684?v=3","gravatar_id":"","url":"https://api.github.com/users/rtnpro","html_url":"https://github.com/rtnpro","followers_url":"https://api.github.com/users/rtnpro/followers","following_url":"https://api.github.com/users/rtnpro/following{/other_user}","gists_url":"https://api.github.com/users/rtnpro/gists{/gist_id}","starred_url":"https://api.github.com/users/rtnpro/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/rtnpro/subscriptions","organizations_url":"https://api.github.com/users/rtnpro/orgs","repos_url":"https://api.github.com/users/rtnpro/repos","events_url":"https://api.github.com/users/rtnpro/events{/privacy}","received_events_url":"https://api.github.com/users/rtnpro/received_events","type":"User","site_admin":false},"body":"mhm","created_at":"2016-09-02T10:10:48Z","updated_at":"2016-09-02T10:10:48Z","html_url":"https://github.com/projectatomic/atomicapp/pull/655#discussion_r77323769","pull_request_url":"https://api.github.com/repos/projectatomic/atomicapp/pulls/655","_links":{"self":{"href":"https://api.github.com/repos/projectatomic/atomicapp/pulls/comments/77323769"},"html":{"href":"https://github.com/projectatomic/atomicapp/pull/655#discussion_r77323769"},"pull_request":{"href":"https://api.github.com/repos/projectatomic/atomicapp/pulls/655"}}},"pull_request":{"url":"https://api.github.com/repos/projectatomic/atomicapp/pulls/655","id":64469298,"html_url":"https://github.com/projectatomic/atomicapp/pull/655","diff_url":"https://github.com/projectatomic/atomicapp/pull/655.diff","patch_url":"https://github.com/projectatomic/atomicapp/pull/655.patch","issue_url":"https://api.github.com/repos/projectatomic/atomicapp/issues/655","number":655,"state":"open","locked":false,"title":"Functional tests for atomicapp","user":{"login":"rtnpro","id":231684,"avatar_url":"https://avatars.githubusercontent.com/u/231684?v=3","gravatar_id":"","url":"https://api.github.com/users/rtnpro","html_url":"https://github.com/rtnpro","followers_url":"https://api.github.com/users/rtnpro/followers","following_url":"https://api.github.com/users/rtnpro/following{/other_user}","gists_url":"https://api.github.com/users/rtnpro/gists{/gist_id}","starred_url":"https://api.github.com/users/rtnpro/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/rtnpro/subscriptions","organizations_url":"https://api.github.com/users/rtnpro/orgs","repos_url":"https://api.github.com/users/rtnpro/repos","events_url":"https://api.github.com/users/rtnpro/events{/privacy}","received_events_url":"https://api.github.com/users/rtnpro/received_events","type":"User","site_admin":false},"body":"- [x] Create base test suite\r\n- [x] Create base test suite for Kubernetes\r\n- [x] Create base test suite for Docker\r\n- [x] Create base test suite for Openshift\r\n- [x] Add tests cases for k8s provider\r\n- [x] Add test cases for docker provider\r\n- [x] Add test cases for openshift provider","created_at":"2016-03-29T13:56:52Z","updated_at":"2016-09-02T10:10:48Z","closed_at":null,"merged_at":null,"merge_commit_sha":"62696231723058c6b56940d1bb2d104589ce03e4","assignee":null,"assignees":[],"milestone":null,"commits_url":"https://api.github.com/repos/projectatomic/atomicapp/pulls/655/commits","review_comments_url":"https://api.github.com/repos/projectatomic/atomicapp/pulls/655/comments","review_comment_url":"https://api.github.com/repos/projectatomic/atomicapp/pulls/comments{/number}","comments_url":"https://api.github.com/repos/projectatomic/atomicapp/issues/655/comments","statuses_url":"https://api.github.com/repos/projectatomic/atomicapp/statuses/836125e6356326457fa46c2dc230207c4bf60710","head":{"label":"rtnpro:functional-tests","ref":"functional-tests","sha":"836125e6356326457fa46c2dc230207c4bf60710","user":{"login":"rtnpro","id":231684,"avatar_url":"https://avatars.githubusercontent.com/u/231684?v=3","gravatar_id":"","url":"https://api.github.com/users/rtnpro","html_url":"https://github.com/rtnpro","followers_url":"https://api.github.com/users/rtnpro/followers","following_url":"https://api.github.com/users/rtnpro/following{/other_user}","gists_url":"https://api.github.com/users/rtnpro/gists{/gist_id}","starred_url":"https://api.github.com/users/rtnpro/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/rtnpro/subscriptions","organizations_url":"https://api.github.com/users/rtnpro/orgs","repos_url":"https://api.github.com/users/rtnpro/repos","events_url":"https://api.github.com/users/rtnpro/events{/privacy}","received_events_url":"https://api.github.com/users/rtnpro/received_events","type":"User","site_admin":false},"repo":{"id":41361459,"name":"atomicapp","full_name":"rtnpro/atomicapp","owner":{"login":"rtnpro","id":231684,"avatar_url":"https://avatars.githubusercontent.com/u/231684?v=3","gravatar_id":"","url":"https://api.github.com/users/rtnpro","html_url":"https://github.com/rtnpro","followers_url":"https://api.github.com/users/rtnpro/followers","following_url":"https://api.github.com/users/rtnpro/following{/other_user}","gists_url":"https://api.github.com/users/rtnpro/gists{/gist_id}","starred_url":"https://api.github.com/users/rtnpro/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/rtnpro/subscriptions","organizations_url":"https://api.github.com/users/rtnpro/orgs","repos_url":"https://api.github.com/users/rtnpro/repos","events_url":"https://api.github.com/users/rtnpro/events{/privacy}","received_events_url":"https://api.github.com/users/rtnpro/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/rtnpro/atomicapp","description":"This is the reference implementation of the Nulecule container application Specification: Atomic App","fork":true,"url":"https://api.github.com/repos/rtnpro/atomicapp","forks_url":"https://api.github.com/repos/rtnpro/atomicapp/forks","keys_url":"https://api.github.com/repos/rtnpro/atomicapp/keys{/key_id}","collaborators_url":"https://api.github.com/repos/rtnpro/atomicapp/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/rtnpro/atomicapp/teams","hooks_url":"https://api.github.com/repos/rtnpro/atomicapp/hooks","issue_events_url":"https://api.github.com/repos/rtnpro/atomicapp/issues/events{/number}","events_url":"https://api.github.com/repos/rtnpro/atomicapp/events","assignees_url":"https://api.github.com/repos/rtnpro/atomicapp/assignees{/user}","branches_url":"https://api.github.com/repos/rtnpro/atomicapp/branches{/branch}","tags_url":"https://api.github.com/repos/rtnpro/atomicapp/tags","blobs_url":"https://api.github.com/repos/rtnpro/atomicapp/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/rtnpro/atomicapp/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/rtnpro/atomicapp/git/refs{/sha}","trees_url":"https://api.github.com/repos/rtnpro/atomicapp/git/trees{/sha}","statuses_url":"https://api.github.com/repos/rtnpro/atomicapp/statuses/{sha}","languages_url":"https://api.github.com/repos/rtnpro/atomicapp/languages","stargazers_url":"https://api.github.com/repos/rtnpro/atomicapp/stargazers","contributors_url":"https://api.github.com/repos/rtnpro/atomicapp/contributors","subscribers_url":"https://api.github.com/repos/rtnpro/atomicapp/subscribers","subscription_url":"https://api.github.com/repos/rtnpro/atomicapp/subscription","commits_url":"https://api.github.com/repos/rtnpro/atomicapp/commits{/sha}","git_commits_url":"https://api.github.com/repos/rtnpro/atomicapp/git/commits{/sha}","comments_url":"https://api.github.com/repos/rtnpro/atomicapp/comments{/number}","issue_comment_url":"https://api.github.com/repos/rtnpro/atomicapp/issues/comments{/number}","contents_url":"https://api.github.com/repos/rtnpro/atomicapp/contents/{+path}","compare_url":"https://api.github.com/repos/rtnpro/atomicapp/compare/{base}...{head}","merges_url":"https://api.github.com/repos/rtnpro/atomicapp/merges","archive_url":"https://api.github.com/repos/rtnpro/atomicapp/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/rtnpro/atomicapp/downloads","issues_url":"https://api.github.com/repos/rtnpro/atomicapp/issues{/number}","pulls_url":"https://api.github.com/repos/rtnpro/atomicapp/pulls{/number}","milestones_url":"https://api.github.com/repos/rtnpro/atomicapp/milestones{/number}","notifications_url":"https://api.github.com/repos/rtnpro/atomicapp/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/rtnpro/atomicapp/labels{/name}","releases_url":"https://api.github.com/repos/rtnpro/atomicapp/releases{/id}","deployments_url":"https://api.github.com/repos/rtnpro/atomicapp/deployments","created_at":"2015-08-25T12:15:42Z","updated_at":"2015-08-25T12:15:42Z","pushed_at":"2016-09-01T09:28:50Z","git_url":"git://github.com/rtnpro/atomicapp.git","ssh_url":"git@github.com:rtnpro/atomicapp.git","clone_url":"https://github.com/rtnpro/atomicapp.git","svn_url":"https://github.com/rtnpro/atomicapp","homepage":"","size":1404,"stargazers_count":0,"watchers_count":0,"language":"Python","has_issues":false,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":1,"forks":0,"open_issues":1,"watchers":0,"default_branch":"master"}},"base":{"label":"projectatomic:master","ref":"master","sha":"e37911e35b1491488289e93f1b95e3cfeb16c375","user":{"login":"projectatomic","id":6852258,"avatar_url":"https://avatars.githubusercontent.com/u/6852258?v=3","gravatar_id":"","url":"https://api.github.com/users/projectatomic","html_url":"https://github.com/projectatomic","followers_url":"https://api.github.com/users/projectatomic/followers","following_url":"https://api.github.com/users/projectatomic/following{/other_user}","gists_url":"https://api.github.com/users/projectatomic/gists{/gist_id}","starred_url":"https://api.github.com/users/projectatomic/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/projectatomic/subscriptions","organizations_url":"https://api.github.com/users/projectatomic/orgs","repos_url":"https://api.github.com/users/projectatomic/repos","events_url":"https://api.github.com/users/projectatomic/events{/privacy}","received_events_url":"https://api.github.com/users/projectatomic/received_events","type":"Organization","site_admin":false},"repo":{"id":32819266,"name":"atomicapp","full_name":"projectatomic/atomicapp","owner":{"login":"projectatomic","id":6852258,"avatar_url":"https://avatars.githubusercontent.com/u/6852258?v=3","gravatar_id":"","url":"https://api.github.com/users/projectatomic","html_url":"https://github.com/projectatomic","followers_url":"https://api.github.com/users/projectatomic/followers","following_url":"https://api.github.com/users/projectatomic/following{/other_user}","gists_url":"https://api.github.com/users/projectatomic/gists{/gist_id}","starred_url":"https://api.github.com/users/projectatomic/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/projectatomic/subscriptions","organizations_url":"https://api.github.com/users/projectatomic/orgs","repos_url":"https://api.github.com/users/projectatomic/repos","events_url":"https://api.github.com/users/projectatomic/events{/privacy}","received_events_url":"https://api.github.com/users/projectatomic/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/projectatomic/atomicapp","description":"This is the reference implementation of the Nulecule container application Specification: Atomic App","fork":false,"url":"https://api.github.com/repos/projectatomic/atomicapp","forks_url":"https://api.github.com/repos/projectatomic/atomicapp/forks","keys_url":"https://api.github.com/repos/projectatomic/atomicapp/keys{/key_id}","collaborators_url":"https://api.github.com/repos/projectatomic/atomicapp/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/projectatomic/atomicapp/teams","hooks_url":"https://api.github.com/repos/projectatomic/atomicapp/hooks","issue_events_url":"https://api.github.com/repos/projectatomic/atomicapp/issues/events{/number}","events_url":"https://api.github.com/repos/projectatomic/atomicapp/events","assignees_url":"https://api.github.com/repos/projectatomic/atomicapp/assignees{/user}","branches_url":"https://api.github.com/repos/projectatomic/atomicapp/branches{/branch}","tags_url":"https://api.github.com/repos/projectatomic/atomicapp/tags","blobs_url":"https://api.github.com/repos/projectatomic/atomicapp/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/projectatomic/atomicapp/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/projectatomic/atomicapp/git/refs{/sha}","trees_url":"https://api.github.com/repos/projectatomic/atomicapp/git/trees{/sha}","statuses_url":"https://api.github.com/repos/projectatomic/atomicapp/statuses/{sha}","languages_url":"https://api.github.com/repos/projectatomic/atomicapp/languages","stargazers_url":"https://api.github.com/repos/projectatomic/atomicapp/stargazers","contributors_url":"https://api.github.com/repos/projectatomic/atomicapp/contributors","subscribers_url":"https://api.github.com/repos/projectatomic/atomicapp/subscribers","subscription_url":"https://api.github.com/repos/projectatomic/atomicapp/subscription","commits_url":"https://api.github.com/repos/projectatomic/atomicapp/commits{/sha}","git_commits_url":"https://api.github.com/repos/projectatomic/atomicapp/git/commits{/sha}","comments_url":"https://api.github.com/repos/projectatomic/atomicapp/comments{/number}","issue_comment_url":"https://api.github.com/repos/projectatomic/atomicapp/issues/comments{/number}","contents_url":"https://api.github.com/repos/projectatomic/atomicapp/contents/{+path}","compare_url":"https://api.github.com/repos/projectatomic/atomicapp/compare/{base}...{head}","merges_url":"https://api.github.com/repos/projectatomic/atomicapp/merges","archive_url":"https://api.github.com/repos/projectatomic/atomicapp/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/projectatomic/atomicapp/downloads","issues_url":"https://api.github.com/repos/projectatomic/atomicapp/issues{/number}","pulls_url":"https://api.github.com/repos/projectatomic/atomicapp/pulls{/number}","milestones_url":"https://api.github.com/repos/projectatomic/atomicapp/milestones{/number}","notifications_url":"https://api.github.com/repos/projectatomic/atomicapp/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/projectatomic/atomicapp/labels{/name}","releases_url":"https://api.github.com/repos/projectatomic/atomicapp/releases{/id}","deployments_url":"https://api.github.com/repos/projectatomic/atomicapp/deployments","created_at":"2015-03-24T19:09:39Z","updated_at":"2016-08-23T04:13:45Z","pushed_at":"2016-09-01T20:30:46Z","git_url":"git://github.com/projectatomic/atomicapp.git","ssh_url":"git@github.com:projectatomic/atomicapp.git","clone_url":"https://github.com/projectatomic/atomicapp.git","svn_url":"https://github.com/projectatomic/atomicapp","homepage":"","size":2204,"stargazers_count":84,"watchers_count":84,"language":"Python","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":65,"mirror_url":null,"open_issues_count":105,"forks":65,"open_issues":105,"watchers":84,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/projectatomic/atomicapp/pulls/655"},"html":{"href":"https://github.com/projectatomic/atomicapp/pull/655"},"issue":{"href":"https://api.github.com/repos/projectatomic/atomicapp/issues/655"},"comments":{"href":"https://api.github.com/repos/projectatomic/atomicapp/issues/655/comments"},"review_comments":{"href":"https://api.github.com/repos/projectatomic/atomicapp/pulls/655/comments"},"review_comment":{"href":"https://api.github.com/repos/projectatomic/atomicapp/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/projectatomic/atomicapp/pulls/655/commits"},"statuses":{"href":"https://api.github.com/repos/projectatomic/atomicapp/statuses/836125e6356326457fa46c2dc230207c4bf60710"}}}}
{"actor":{"display_login":"rtnpro"}}