Exemplo n.º 1
0
 def test_strip_trailing_slash(self, app: SamsiteFlask,
                               image_fetcher: ImageFetcher) -> None:
     assert image_fetcher.get_internal_path(
         f"{self.path}/") == f"{app.STATIC_DIR}/{self.path}"
Exemplo n.º 2
0
 def test_strip_dir_navigation(self, app: SamsiteFlask,
                               image_fetcher: ImageFetcher) -> None:
     assert (image_fetcher.get_internal_path(f"../../../{self.path}") ==
             f"{app.STATIC_DIR}/{self.path}")
Exemplo n.º 3
0
 def test_append_store_path(self, app: SamsiteFlask,
                            image_fetcher: ImageFetcher) -> None:
     assert image_fetcher.get_internal_path(
         self.path) == f"{app.STATIC_DIR}/{self.path}"