title: relative URL paths when serving static files with FastAPI/Starlette
body: <p>I have a simple FastAPI application that serves a file <code>test.html</code> in <code>app/main.py</code> like so:</p>
  
  <pre><code>@app.get('/')
  def index():
    return FileResponse('static/test.html')
  </code></pre>
  
  <p>The directory structure is like so:</p>
  
  <pre><code>app/main.py
  app/static/test.html
  </code></pre>
  
  <p>Can I change this do that it works with a modified directory structure where <code>app/</code> and <code>static/</code> are siblings? </p>
  
  <p>I have tried <code>return FileResponse('../static/test.html')</code> but that has not worked so far; the resulting error is "RuntimeError: File at path ../static/test.html does not exist."</p>