Coverage for docs_src/custom_response/tutorial009b.py: 100%

7 statements  

« prev     ^ index     » next       coverage.py v7.6.1, created at 2024-08-08 03:53 +0000

1from fastapi import FastAPI 1abcde

2from fastapi.responses import FileResponse 1abcde

3 

4some_file_path = "large-video-file.mp4" 1abcde

5app = FastAPI() 1abcde

6 

7 

8@app.get("/", response_class=FileResponse) 1abcde

9async def main(): 1abcde

10 return some_file_path 1abcde