[Cvsshell-devel] CVS: cvsshell/testing refstdout,1.1,1.2 run-test.py,1.1,1.2 testinput,1.1,1.2
Status: Beta
Brought to you by:
stefanheimann
|
From: Stefan H. <ste...@us...> - 2002-03-11 12:02:18
|
Update of /cvsroot/cvsshell/cvsshell/testing
In directory usw-pr-cvs1:/tmp/cvs-serv29583/testing
Modified Files:
refstdout run-test.py testinput
Log Message:
* added support for filtering the file-listing
* add now ask if the files should be added.
Index: refstdout
===================================================================
RCS file: /cvsroot/cvsshell/cvsshell/testing/refstdout,v
retrieving revision 1.1
retrieving revision 1.2
diff -C2 -d -r1.1 -r1.2
*** refstdout 10 Mar 2002 23:13:01 -0000 1.1
--- refstdout 11 Mar 2002 12:02:15 -0000 1.2
***************
*** 2,5 ****
--- 2,6 ----
====== initializing the repository ======
====== importing the testdata ======
+ N testdata/I_AM_HERE.pyc
N testdata/test1
N testdata/test2
***************
*** 26,31 ****
====== Testing add ======
=== add 1 ===
- === add 2 ===
- === add 3 ===
RCS file: /tmp/cvsroot/testdata/addtest1,v
done
--- 27,30 ----
***************
*** 53,56 ****
--- 52,56 ----
done
CVS
+ I_AM_HERE.pyc
addtest1
addtest2
***************
*** 61,64 ****
--- 61,65 ----
====== Testing remove ======
CVS
+ I_AM_HERE.pyc
addtest1
dirX
***************
*** 77,81 ****
This software is released under the GPL.
CvsShell started.
! {a} ~/cvsshell/testing [--]
$ cd /tmp
{a} /private/tmp [--]
--- 78,82 ----
This software is released under the GPL.
CvsShell started.
! {a} /private/tmp [--]
$ cd /tmp
{a} /private/tmp [--]
***************
*** 90,93 ****
--- 91,96 ----
$ echo "You are file test2" > test2
{a} /private/tmp/testdata [--]
+ $ echo "You are a file that should by filtered" > I_AM_HERE.pyc
+ {a} /private/tmp/testdata [--]
$ mkdir testdir
{a} /private/tmp/testdata [--]
***************
*** 184,190 ****
{a} /private/tmp/testdata [/tmp/cvsroot]
$ cvs -z 3 -d /tmp/cvsroot add addtest1
! {a} /private/tmp/testdata [/tmp/cvsroot]
! $ echo === add 2 ===
! {a} /private/tmp/testdata [/tmp/cvsroot]
$ echo "I am addtest2" > addtest2
{a} /private/tmp/testdata [/tmp/cvsroot]
--- 187,193 ----
{a} /private/tmp/testdata [/tmp/cvsroot]
$ cvs -z 3 -d /tmp/cvsroot add addtest1
!
! The files have been scheduled for addition.
! Should I run `commit' to add the files to the repository (yes|no)? {a} /private/tmp/testdata [/tmp/cvsroot]
$ echo "I am addtest2" > addtest2
{a} /private/tmp/testdata [/tmp/cvsroot]
***************
*** 195,202 ****
{a} /private/tmp/testdata [/tmp/cvsroot]
$ cd /private/tmp/testdata
! cvs -z 3 -d /tmp/cvsroot add -m 'sdfasdf' addtest2
! {a} /private/tmp/testdata [/tmp/cvsroot]
! $ echo === add 3 ===
! {a} /private/tmp/testdata [/tmp/cvsroot]
$ mkdir dirX
{a} /private/tmp/testdata [/tmp/cvsroot]
--- 198,207 ----
{a} /private/tmp/testdata [/tmp/cvsroot]
$ cd /private/tmp/testdata
! cvs -z 3 -d /tmp/cvsroot add -m 'sdfasdf' addtest2
! :
! 0 A addtest2
!
! The files have been scheduled for addition.
! Should I run `commit' to add the files to the repository (yes|no)? {a} /private/tmp/testdata [/tmp/cvsroot]
$ mkdir dirX
{a} /private/tmp/testdata [/tmp/cvsroot]
***************
*** 206,210 ****
{a} /private/tmp/testdata [/tmp/cvsroot]
$ cvs -z 3 -d /tmp/cvsroot -Q add -m 'sdfa' dirX
! {a} /private/tmp/testdata [/tmp/cvsroot]
$ cvs -z 3 -q -d /tmp/cvsroot update -P
:
--- 211,217 ----
{a} /private/tmp/testdata [/tmp/cvsroot]
$ cvs -z 3 -d /tmp/cvsroot -Q add -m 'sdfa' dirX
!
! The files have been scheduled for addition.
! Should I run `commit' to add the files to the repository (yes|no)? {a} /private/tmp/testdata [/tmp/cvsroot]
$ cvs -z 3 -q -d /tmp/cvsroot update -P
:
***************
*** 216,221 ****
{a} /private/tmp/testdata [/tmp/cvsroot]
$ cd /private/tmp/testdata
! cvs -z 3 -d /tmp/cvsroot -Q add -m 'sdfas' dirX/addtest3 dirX/addtest4
! {a} /private/tmp/testdata [/tmp/cvsroot]
$ cd /private/tmp/testdata
cvs -z 3 -d /tmp/cvsroot -Q commit -m 'dummy'
--- 223,233 ----
{a} /private/tmp/testdata [/tmp/cvsroot]
$ cd /private/tmp/testdata
! cvs -z 3 -d /tmp/cvsroot -Q add -m 'sdfas' dirX/addtest3 dirX/addtest4
! dirX:
! 0 A addtest3
! 1 A addtest4
!
! The files have been scheduled for addition.
! Should I run `commit' to add the files to the repository (yes|no)? {a} /private/tmp/testdata [/tmp/cvsroot]
$ cd /private/tmp/testdata
cvs -z 3 -d /tmp/cvsroot -Q commit -m 'dummy'
Index: run-test.py
===================================================================
RCS file: /cvsroot/cvsshell/cvsshell/testing/run-test.py,v
retrieving revision 1.1
retrieving revision 1.2
diff -C2 -d -r1.1 -r1.2
*** run-test.py 10 Mar 2002 23:13:01 -0000 1.1
--- run-test.py 11 Mar 2002 12:02:15 -0000 1.2
***************
*** 33,36 ****
--- 33,37 ----
os.system('rm -rf /tmp/testdata /tmp/cvsroot') # little clean-up
os.unlink(os.path.join(os.environ['HOME'], '.cvsshellrc'))
+ os.chdir('/tmp')
stdin, stdout, stderr = os.popen3('python %s/../src/cvs_shell.py -v' % thisDir)
stdin.write(testcode)
***************
*** 45,62 ****
print
print '======== diff of stdout ========'
! print '< is the reference, > is the current result:'
! os.system('diff %s %s' % (refstdout, logstdout))
if os.path.exists(refstderr):
print
print '======== diff of stderr ========'
! print '< is the reference, > is the current result:'
! os.system('diff %s %s' % (refstderr, logstderr))
a = raw_input('Should the result be saved as the new reference (yes|no)? ')
if a == 'yes':
os.rename(logstdout, refstdout)
os.rename(logstderr, refstderr)
!
if __name__ == '__main__':
! runTest()
--- 46,66 ----
print
print '======== diff of stdout ========'
! print 'reference, current result:'
! os.system('diff --context %s %s' % (refstdout, logstdout))
if os.path.exists(refstderr):
print
print '======== diff of stderr ========'
! print 'reference, result:'
! os.system('diff --context %s %s' % (refstderr, logstderr))
a = raw_input('Should the result be saved as the new reference (yes|no)? ')
if a == 'yes':
os.rename(logstdout, refstdout)
os.rename(logstderr, refstderr)
! os.unlink(os.path.join(os.environ['HOME'], '.cvsshellrc'))
if __name__ == '__main__':
! if sys.platform[:3] == 'win':
! print "Tests don't run on windows."
! else:
! runTest()
Index: testinput
===================================================================
RCS file: /cvsroot/cvsshell/cvsshell/testing/testinput,v
retrieving revision 1.1
retrieving revision 1.2
diff -C2 -d -r1.1 -r1.2
*** testinput 10 Mar 2002 23:13:01 -0000 1.1
--- testinput 11 Mar 2002 12:02:15 -0000 1.2
***************
*** 5,8 ****
--- 5,9 ----
echo "You are file test1" > test1
echo "You are file test2" > test2
+ echo "You are a file that should by filtered" > I_AM_HERE.pyc
mkdir testdir
echo "You are file test3" > testdir/test3
***************
*** 67,72 ****
--- 68,75 ----
echo "I am addtest4" > dirX/addtest4
add -m 'sdfa' -Q dirX
+ y
update
add -m 'sdfas' -Q 2,3
+ n
commit -Q -m 'dummy'
ls
|