eliminado código comentado
This commit is contained in:
@ -1,31 +1,6 @@
|
|||||||
import pytest
|
import pytest
|
||||||
|
|
||||||
# from pathlib import Path
|
|
||||||
from modules.copier import copiar_ficheiros_para_destino
|
from modules.copier import copiar_ficheiros_para_destino
|
||||||
# import tempfile
|
|
||||||
|
|
||||||
# class TestCopier(unittest.TestCase):
|
|
||||||
# def setUp(self) -> None:
|
|
||||||
# self.origem = tempfile.TemporaryDirectory()
|
|
||||||
# self.destino = tempfile.TemporaryDirectory()
|
|
||||||
# (Path(self.origem.name) / "teste.txt").write_text("conteudo")
|
|
||||||
#
|
|
||||||
# def tearDown(self) -> None:
|
|
||||||
# self.origem.cleanup()
|
|
||||||
# self.destino.cleanup()
|
|
||||||
#
|
|
||||||
# def test_copiar_ficheiros_para_destino(self):
|
|
||||||
# ficheiros = [str(f) for f in Path(self.origem.name).iterdir()]
|
|
||||||
# copiar_ficheiros_para_destino(
|
|
||||||
# ficheiros, self.destino.name, categorizar_data=False
|
|
||||||
# )
|
|
||||||
# copiados = list(Path(self.destino.name).rglob("teste.txt"))
|
|
||||||
# self.assertEqual(len(copiados), 1)
|
|
||||||
# self.assertTrue(copiados[0].exists())
|
|
||||||
#
|
|
||||||
#
|
|
||||||
# if __name__ == "__main__":
|
|
||||||
# unittest.main()
|
|
||||||
|
|
||||||
|
|
||||||
def test_copiar_ficheiros_para_destino(tmp_path):
|
def test_copiar_ficheiros_para_destino(tmp_path):
|
||||||
|
|||||||
Reference in New Issue
Block a user