Commit graph

7 commits

Author SHA1 Message Date
Shinichiro Hamaji
8f58a4a58a Fix the windows failure
by not using slashes in symlink targets.
2017-04-11 12:04:55 +09:00
Shinichiro Hamaji
d556c9e398 ln: Fix how it selects the form
ln had a bunch of problems:

1. `ln -s target` didn't work (2nd form in help).
2. `ln -t tmp` wasn't an error. We should check if files are
   empty first.
3. `ln -s file dir` didn't create dir/file.
4. `ln -s -T file dir` was removing `dir`.
5. Test cases for 4 say this is for compatibility with GNU
   coreutils but I couldn't find this feature.
2017-04-09 02:32:57 +09:00
Shinichiro Hamaji
47acbb0e82 ln: Use basename when target directory is specfied
The following should work, but without this patch, it tries
to create the link as x/y and it fails with EEXIST.

$ mkdir -p x/y
$ ln -s -t . x/y
2017-04-01 23:22:14 +09:00
nathanross
aa6ee03be3 tests: remove helper function boilerplate via macros 2016-08-23 08:04:02 -04:00
Nathan Ross
99b39e4237 tests: normalize around chaining asserts
Although for some tests this adds characters
we still use them there because the
brevity cost is now worth the benefit in
terms of instant, natural-language readability
and recognizability for people not familiar
with this tests of this module or even the project
2016-08-13 17:59:21 -04:00
Nathan Ross
569cd162d3 tests: refactor conventional TestScenario usage
Updates to individual integration tests

  - use proposed conventional approach to beginning tests

  - use new convenience functions for using fixtures

  - use new names for TestScenario

Updates to integration test modules

  - add proposed conventional module-level functions

Updates to test/common/util.rs

  - rename TestSet, and its methods, for semantic clarity

  - create convenience functions for use of fixtures

  - delete convenience functions obsoleted by new conventions
2016-08-01 13:42:00 -04:00
Joseph Crail
7ef4bb37a8 tests: consolidate into one crate
The main motivation is to move toward running those tests for a specific
target, that is, if a test won't run on Windows, then we shouldn't build
it. This was previously the default behavior and prevented a successful
run on AppVeyor.

I borrowed this pattern from the tests in the Cargo project.
2016-05-22 03:46:54 -04:00
Renamed from tests/ln.rs (Browse further)