user1703761
user1703761

Reputation: 1104

How to serve static files with capybara and cucumber

I want to run acceptance tests for an rss feed reader and I need an URL to an atom or rss feed. Ive got a small file which contains my sample atom/rss and i want to access it from a locally running webserver.

Basically i want to add something like this to my feed url input field:

http://localhost:8080/feed1.atom.xml

How do I serve my example file under that url?

Upvotes: 1

Views: 236

Answers (1)

poseid
poseid

Reputation: 7156

Maybe with a static file server, e.g. a Python one is nice and fast:

→ python -m SimpleHTTPServer 8080
Serving HTTP on 0.0.0.0 port 8080 ...

You need to copy a file at feed1.atom.xml at the location where you start up the static file server.

Upvotes: 1

Related Questions