title: Using a Jetty Server with JUnit tests
body: <p>I've been trying to test my web app by starting a Jetty server in the BeforeClass method of my JUnit test case and then using a HttpClient to form request to the server. I get the server to start without any issues, but I keep getting 404's when I try to make  a request. </p>
  
  <p>The configuration of my server is like the following:</p>
  
  <pre><code>  public void start() throws Exception {
          if (server == null) {
              server = new Server(PORT);
              server.setStopAtShutdown(true);
  
              wac = new WebAppContext();
              wac.setContextPath("/app");
              wac.setResourceBase("war");
              wac.setClassLoader(this.getClass().getClassLoader());
              server.addHandler(wac);
  
              server.start();
          }
     }    
  </code></pre>
  
  <p>Is there something wrong with my config? The server is running, and I can see that I am hitting it, it just can't find any resources.</p>