# -*- coding: utf-8 -*-
"""
Created on Sat Aug 12 19:16:24 2017

@author: Shaun Werkhoven
"""

import pytest
import os
import tempfile
import recognition_server
import unittest
import json
import requests
from base64 import b64encode


class Recognition_ServerTestCase(unittest.TestCase):
    def setUp(self):
        recognition_server.app.config['TESTING'] = True
        self.app = recognition_server.app.test_client()
        
    
if __name__ == '__main__':
        unittest.main()
@@ -116,24 +116,8 @@
  os%0A
-import tempfile%0A
 impo
@@ -170,53 +170,8 @@
 son%0A
-import requests%0Afrom base64 import b64encode%0A
 %0A%0Acl
@@ -359,19 +359,479 @@
 ()%0A     
+%0A
    
+ def tearDown(self):%0A        pass%0A%0A    def test_get_imgs(self):%0A        %22%22%22Check that root exists%22%22%22%0A        rv = self.app.get('/img/api/v1.0/images')%0A        self.assertEqual(rv.status_code, 200)%0A        assert b'images' in rv.data%0A      %0A    def test_non_existing_function(self):%0A        %22%22%22Check that 404 gets thrown for a function that doesn't exist%22%22%22%0A        rv = self.app.get('/img/api/v1.0/a-bad-address')%0A        self.assertEqual(rv.status_code, 404)
 %0A    %0Aif

add tests to get all images, and test a non-existent function