diff options
| author | Dan Allen <dan.j.allen@gmail.com> | 2018-04-03 23:44:47 -0600 |
|---|---|---|
| committer | Dan Allen <dan.j.allen@gmail.com> | 2018-04-03 23:48:27 -0600 |
| commit | 004bd1857cc7f275034018034ee7b0f555d20f3a (patch) | |
| tree | 7937dfafbfeb6122d73d847ab0945e1f932fca2c /test/paths_test.rb | |
| parent | 59c722e98da6bc9e6c117799276efea8bd862dcb (diff) | |
assert that PathResolver#system_path removes self references in start path
Diffstat (limited to 'test/paths_test.rb')
| -rw-r--r-- | test/paths_test.rb | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/test/paths_test.rb b/test/paths_test.rb index 46a0ba42..fe984584 100644 --- a/test/paths_test.rb +++ b/test/paths_test.rb @@ -212,7 +212,9 @@ context 'Path Resolver' do test 'resolves and normalizes start with target is empty' do pwd = File.expand_path Dir.pwd assert_equal '/home/doctor/docs', (@resolver.system_path '', '/home/doctor/docs') + assert_equal '/home/doctor/docs', (@resolver.system_path '', '/home/doctor/./docs') assert_equal '/home/doctor/docs', (@resolver.system_path nil, '/home/doctor/docs') + assert_equal '/home/doctor/docs', (@resolver.system_path nil, '/home/doctor/./docs') assert_equal %(#{pwd}/assets/images), (@resolver.system_path nil, 'assets/images') result, warnings = redirect_streams do |_, err| [(@resolver.system_path '', '../assets/images', JAIL), err.string] |
