From c721e6a15fc865ef13043b2d9ce5d674c1520071 Mon Sep 17 00:00:00 2001 From: Dan Vanderkam Date: Wed, 12 Nov 2014 12:07:17 -0500 Subject: [PATCH] Allow loading data from anywhere in __tests__ --- cycledash/views.py | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/cycledash/views.py b/cycledash/views.py index 7550e9c..43258fc 100644 --- a/cycledash/views.py +++ b/cycledash/views.py @@ -168,8 +168,7 @@ def trends(caller_name): # (It is added on automatically when requesting a HDFS file). @app.route('/vcf/') def hdfs_vcf(vcf_path): - if (app.config['ALLOW_LOCAL_VCFS'] and - '__tests__/js/data' in vcf_path): + if app.config['ALLOW_LOCAL_VCFS'] and vcf_path.startswith('__tests__/'): # we only load test data that we mean to load locally vcf_text = open(vcf_path).read() else: