To run it:
> cd fandango
> git clone [email protected]:fandango/api-movieclips.git api-movieclips
> chmod +x looper.sh
> ./looper.sh http://dev-backstage.fandango.com/movieclips
#!/bin/bash | |
echo "Running diffs against responses from service at: $1" | |
for run in {1..9999} | |
do | |
curl $1/mobile/videos/search?query=Star+Trek\&pageSize=1 | json_pp | diff api-movieclips/test/fixtures/search.json - | |
if [ $? -eq 1 ]; then | |
osascript -e 'display notification "MovieClips API Video Search call failed" with title "MovieClips API Failure"' | |
fi | |
curl $1/mobile/videos/autocomplete?query=the\&pageSize=1 | json_pp | diff api-movieclips/test/fixtures/autocomplete.json - | |
if [ $? -eq 1 ]; then | |
osascript -e 'display notification "Autocomplete failed" with title "MovieClips API Failure"' | |
fi | |
curl $1/mobile/playlists/auto/447801411744 | json_pp | diff api-movieclips/test/fixtures/autoplaylist.json - | |
if [ $? -eq 1 ]; then | |
osascript -e 'display notification "Autoplaylist failed" with title "MovieClips API Failure"' | |
fi | |
curl $1/mobile/main | json_pp | diff api-movieclips/test/fixtures/home.json - | |
if [ $? -eq 1 ]; then | |
osascript -e 'display notification "Mobile Main failed" with title "MovieClips API Failure"' | |
fi | |
done | |
To run it:
> cd fandango
> git clone [email protected]:fandango/api-movieclips.git api-movieclips
> chmod +x looper.sh
> ./looper.sh http://dev-backstage.fandango.com/movieclips