summaryrefslogtreecommitdiff
path: root/test/paths_test.rb
diff options
context:
space:
mode:
authorCharles Moulliard <ch007m@gmail.com>2014-02-03 12:27:18 +0100
committerDan Allen <dan.j.allen@gmail.com>2014-02-05 17:03:09 -0700
commit47a17845318ca5cc0ce101dc7e8a5fd4d7a22c98 (patch)
treedac68ead7727eb46e175d01e8ab143b446fe13a6 /test/paths_test.rb
parent5a3854c98dc4dd0b81f6fb15501c9e5ff4af760a (diff)
refactor unit tests so they work in RubyMine
- explicitly add the test and lib directory to the load path - switch to the project root before running tests - add UTF-8 encoding magic header to all test files - exclude .gem file at root of project (where RubyMine puts it) This commit was modified from the original pull request by @mojavelinux
Diffstat (limited to 'test/paths_test.rb')
-rw-r--r--test/paths_test.rb6
1 files changed, 5 insertions, 1 deletions
diff --git a/test/paths_test.rb b/test/paths_test.rb
index 235f391f..ea7b0a5b 100644
--- a/test/paths_test.rb
+++ b/test/paths_test.rb
@@ -1,4 +1,8 @@
-require 'test_helper'
+# encoding: UTF-8
+unless defined? ASCIIDOCTOR_PROJECT_DIR
+ $: << File.dirname(__FILE__); $:.uniq!
+ require 'test_helper'
+end
context 'Path Resolver' do
context 'Web Paths' do