예제 #1
0
파일: tests.py 프로젝트: holysugar/heso
    def test_update_heso(self):
        heso = self._make_heso()
        application.create_heso(heso)
        reponame = self._get_diff_repos()[0]
        expected = application.get_heso(reponame)
        expected['description'] = "This heso is updated."
        application.update_heso(reponame, expected)

        result = application.get_heso(reponame)
        self.assertEqual(result['description'], expected['description'])
        self.assertEqual(result['files'][0]['filename'],
                         expected['files'][0]['filename'])
예제 #2
0
파일: tests.py 프로젝트: Epictetus/heso
    def test_update_heso(self):
        heso = {'description':"This is description.",
                'files':[{'filename':"heso_test.py",
                          'document':"import heso"}]}
        application.create_heso(heso)
        reponame = self._get_diff_repos()[0]
        expected = application.get_heso(reponame)
        expected['description'] = "This heso is updated."
        application.update_heso(reponame, expected)

        result = application.get_heso(reponame)
        self.assertEqual(result['description'], expected['description'])
        self.assertEqual(result['files'][0]['filename'],
                         expected['files'][0]['filename'])
예제 #3
0
파일: tests.py 프로젝트: holysugar/heso
 def test_get_heso(self):
     heso = self._make_heso()
     application.create_heso(heso)
     reponame = self._get_diff_repos()[0]
     result = application.get_heso(reponame)
     self.assertEqual(result['description'], heso['description'])
     self.assertEqual(result['files'][0]['filename'],
                      heso['files'][0]['filename'])
예제 #4
0
파일: tests.py 프로젝트: Epictetus/heso
 def test_get_heso(self):
     heso = {'description': "This is description.",
             'files':[{'filename': "heso_test.py",
                       'document': "import heso"}]}
     application.create_heso(heso)
     reponame = self._get_diff_repos()[0]
     result = application.get_heso(reponame)
     self.assertEqual(result['description'], heso['description'])
     self.assertEqual(result['files'][0]['filename'],
                      heso['files'][0]['filename'])