def path(): # first initializes the Image tools class test_image = ImageTools(TEST_IMAGE_DIR, False) # finally, calls the path property test_path = test_image.path() return test_path
def binary(): # first initializes the Image tools class test_image = ImageTools(TEST_IMAGE_DIR, False) # finally, calls the binary property test_bin = test_image._binary return test_bin
def name(): # first initializes the Imagetools class test_image = ImageTools(TEST_IMAGE_DIR, False) # finally, calls the name property test_name = test_image._name return test_name
def size(): # first initializes the Image tools class test_image = ImageTools(TEST_IMAGE_DIR, False) # finally, calls the size property test_size = test_image.size return test_size
def ext(): # first initializes the Imagetools class test_image = ImageTools(TEST_IMAGE_DIR, False) # finally, calls the format property test_format = test_image._format return test_format
def height(): # first initializes the Imagetools class test_image = ImageTools(TEST_IMAGE_DIR, False) # finally, calls the height property test_height = test_image._height return test_height
def file_exts(): # Skips initialization as image is not needed and calls the available_exts property extensions = ImageTools.available_ext() return extensions
def test_rep(): test = ImageTools('C:\\Users\\ghub4\\Python-Image-and-Video-tools\\docs\\test_utils\\test_image\\testbird.jfif', False) assert rep() == repr(test)
def rep(): # first initializes the Imagetools class test_image = ImageTools(TEST_IMAGE_DIR, False) # finally, calls the __repr__ dunder function return repr(test_image)