Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
L
lsh
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Deploy
Releases
Model registry
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
GitLab community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
LSH
lsh
Commits
d2dfee70
Commit
d2dfee70
authored
Nov 14, 2004
by
Niels Möller
Browse files
Options
Downloads
Patches
Plain Diff
Test cases for lcp.
Rev: src/testsuite/lcp-test:1.1
parent
91a2501b
Branches
Branches containing commit
Tags
Tags containing commit
No related merge requests found
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
src/testsuite/lcp-test
+46
-0
46 additions, 0 deletions
src/testsuite/lcp-test
with
46 additions
and
0 deletions
src/testsuite/lcp-test
0 → 100755
+
46
−
0
View file @
d2dfee70
#! /bin/sh
echo
testing lcp
if
[
-z
"
$srcdir
"
]
;
then
srcdir
=
`
pwd
`
fi
.
$srcdir
/functions.sh
spawn_lshd
||
test_fail
spawn_lsh
-G
||
test_fail
rm
-rf
"
$TEST_HOME
"
/files
mkdir
"
$TEST_HOME
"
/files
LCP_RSH
=
../lshg
export
LCP_RSH
LCP
=
"
$srcdir
/../lcp"
echo
foo
>
lcp-file-1.txt
echo
bar
>
lcp-file-2.txt
# Copy from local files to remote files
$LCP
lcp-file-1.txt localhost:files
||
die
"lcp failed, 1"
cmp lcp-file-1.txt
"
$TEST_HOME
/files/lcp-file-1.txt"
||
die
"files differ, 2"
$LCP
lcp-file-1.txt localhost:files
&&
die
"lcp to existing file succeeded, 3"
$LCP
lcp-file-2.txt localhost:files/lcp-file-1.txt
&&
die
"lcp to existing file succeeded, 4"
$LCP
-f
lcp-file-2.txt localhost:files/lcp-file-1.txt
||
die
"lcp -f to existing file failed, 5"
cmp lcp-file-2.txt
"
$TEST_HOME
/files/lcp-file-1.txt"
||
die
"files differ, 6"
# Copy from remote files to local directory
$LCP
localhost:files/lcp-file-1.txt
.
&&
die
"lcp to existing file succeeded, 11"
echo
baz
>
lcp-file-1.txt
$LCP
-f
localhost:files/lcp-file-1.txt
.
||
die
"lcp -f to existing file failed, 12"
cmp lcp-file-1.txt
"
$TEST_HOME
/files/lcp-file-1.txt"
||
die
"files differ, 13"
rm
-f
lcp-file-3.txt
$LCP
localhost:files/lcp-file-1.txt lcp-file-3.txt
||
die
"lcp failed, 14"
cmp
"
$TEST_HOME
/files/lcp-file-1.txt"
lcp-file-3.txt
||
die
"files differ, 15"
test_success
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment