Tests for insert_after_build_dir_exn

This commit is contained in:
Rudi Grinberg 2018-05-08 17:18:45 +07:00
parent fadc57040b
commit 6ee133b4dd
1 changed files with 19 additions and 0 deletions

View File

@ -111,3 +111,22 @@ Path.is_local (Path.absolute "relative/path")
[%%expect{|
- : bool = false
|}]
Path.insert_after_build_dir_exn Path.root "foobar"
[%%expect{|
Exception: Stdune__Exn.Code_error <abstr>.
Raised at file "src/stdune/exn.ml", line 30, characters 37-131
Called from file "toplevel/toploop.ml", line 180, characters 17-56
|}]
Path.insert_after_build_dir_exn Path.build_dir "foobar"
[%%expect{|
Exception: Stdune__Exn.Code_error <abstr>.
Raised at file "src/stdune/exn.ml", line 30, characters 37-131
Called from file "toplevel/toploop.ml", line 180, characters 17-56
|}]
Path.insert_after_build_dir_exn (Path.relative Path.build_dir "qux") "foobar"
[%%expect{|
- : Stdune.Path.t = _build/foobar/qux
|}]