File tree Expand file tree Collapse file tree 3 files changed +8
-3
lines changed
Expand file tree Collapse file tree 3 files changed +8
-3
lines changed Original file line number Diff line number Diff line change @@ -159,6 +159,4 @@ cython_debug/
159159# and can be added to the global gitignore or merged into this file. For a more nuclear
160160# option (not recommended) you can uncomment the following to ignore the entire idea folder.
161161# .idea/
162- src /lighthouseweb3 /functions /download.py
163-
164162image.png
Original file line number Diff line number Diff line change @@ -32,6 +32,7 @@ def test_download_file(self):
3232 "Qmd5MBBScDUV3Ly8qahXtZFqyRRfYSmUwEcxpYcV4hzKfW" )
3333 self .assertIsInstance (res , bytes , "type doesn't match" )
3434 self .assertEqual (res , b'tests/testdir/' , "data doesn't match" )
35+ self .assertEqual (res .decode ('utf-8' ), 'tests/testdir/' )
3536
3637 def test_download_blob_file (self ):
3738 """test download_blob function"""
@@ -43,6 +44,5 @@ def test_download_blob_file(self):
4344 123939 , "File Size dont match" )
4445
4546
46-
4747if __name__ == "__main__" :
4848 unittest .main ()
Original file line number Diff line number Diff line change @@ -86,6 +86,13 @@ def test_upload_with_tag(self):
8686 self .assertEqual (res .get ("data" ).get ("Hash" ), tagData .get (
8787 "data" ).get ("cid" ), "Tag dont match" )
8888
89+ def test_tag_notFound (self ):
90+ """test Upload with tag function"""
91+ l = Lighthouse (os .environ .get ("LIGHTHOUSE_TOKEN" ))
92+ tag = generate_random_string (9 )
93+ tagData = l .getTagged (tag )
94+ self .assertEqual (None , tagData .get ("data" ), "Tag dont match" )
95+
8996
9097if __name__ == "__main__" :
9198 unittest .main ()
You can’t perform that action at this time.
0 commit comments