code: def test_file_uploader():
      file_uploader = uploader.FileUploader(
          presigned_url="https://test-url",
          source_file="test.txt",
          total_size=100,
          name="test.txt",
      )
      file_uploader.progress = MagicMock()
  
      file_uploader.upload()
  
      file_uploader.progress.add_task.assert_called_once_with(
          "upload", filename="test.txt", total=100
      )
      file_uploader.progress.start.assert_called_once()
      file_uploader.progress.update.assert_called_once_with(
          ANY, advance=9
      )
  
file_path: pytorch-lightning/tests/tests_app/source_code/test_uploader.py
imports: from unittest import mock
  from unittest.mock import ANY, MagicMock
  import pytest
  from lightning.app.source_code import uploader
label_desc: Use image node_id 1 for calling a global function with example usage: test_file_uploader() without return types