Windows Tests

Friedrich, Anna-Christina Anna-Christina.Friedrich at draeger.com
Thu Apr 21 02:13:46 CDT 2011


Hello,

a sample converted batch script: "test-convert-hg-startrev.t" was converted into "test-convert-hg-startrev.bat". 
I forgot to mention that you need to have "vcvarsall.bat" in your system, otherwise the Testsuite does not run on Windows. Maybe you know about this problem.
I cannot send the files as an attachment, therefore I merely copy the content to this mail. 

Best regards
Anna Friedrich 


test-convert-hg-startrev.bat:

@echo off

echo [extensions] >>  %HGRCPATH% 
echo graphlog = >>  %HGRCPATH% 
echo convert = >>  %HGRCPATH% 
echo [convert] >>  %HGRCPATH% 
echo hg.saverev = yes >>  %HGRCPATH% 

call hg  init source
cd source
echo a > a
echo b > b
call hg  ci -d "0 0" -qAm "0: add a b"
echo c > c
call hg  ci -d "1 0" -qAm "1: add c"
call hg  copy a e
echo b >> b
call hg  ci -d "2 0" -qAm "2: copy e from a, change b"
call hg  up -C 0
echo a >> a
call hg  ci -d "3 0" -qAm "3: change a"
call hg  merge
call hg  copy b d
call hg  ci -d "4 0" -qAm "4: merge 2 and 3, copy d from b"
echo a >> a
call hg  ci -d "5 0" -qAm "5: change a"
cd ..
rem Convert from null revision
call hg  convert --config convert.hg.startrev=null source full
set glog1=full
call :glog
@echo off
rmdir /S /Q   full
rem Convert from zero revision
call hg  convert --config convert.hg.startrev=0 source full
set glog1=full
call :glog
@echo off
rem Convert from merge parent
call hg  convert --config convert.hg.startrev=1 source conv1
set glog1=conv1
call :glog
@echo off
cd conv1
rem Check copy preservation
call hg  log --follow --copies e
rem Check copy removal on missing parent
call hg  log --follow --copies d
call hg  cat -r tip a b
call hg  -q verify
cd ..
rem Convert from merge
call hg  convert --config convert.hg.startrev=4 source conv4
set glog1=conv4
call :glog
@echo off
cd conv4
call hg  up -C
call hg  cat -r tip a b
call hg  -q verify
cd ..
goto EOF
:glog
call hg  -R "%glog1%" glog --template "{rev} "{desc}" files: {files}\n"

:EOF
@echo on


The corresponding output file test-convert-hg-startrev.bat.out:


1 files updated, 0 files merged, 2 files removed, 0 files unresolved
merging a and e to e
2 files updated, 1 files merged, 0 files removed, 0 files unresolved
(branch merge, don't forget to commit)
initializing destination full repository
scanning source...
sorting...
converting...
5 0: add a b
4 1: add c
3 2: copy e from a, change b
2 3: change a
1 4: merge 2 and 3, copy d from b
0 5: change a
o  5 5: change a files: a
|
o    4 4: merge 2 and 3, copy d from b files: d e
|\
| o  3 3: change a files: a
| |
o |  2 2: copy e from a, change b files: b e
| |
o |  1 1: add c files: c
|/
o  0 0: add a b files: a b

initializing destination full repository
scanning source...
sorting...
converting...
5 0: add a b
4 1: add c
3 2: copy e from a, change b
2 3: change a
1 4: merge 2 and 3, copy d from b
0 5: change a
o  5 5: change a files: a
|
o    4 4: merge 2 and 3, copy d from b files: d e
|\
| o  3 3: change a files: a
| |
o |  2 2: copy e from a, change b files: b e
| |
o |  1 1: add c files: c
|/
o  0 0: add a b files: a b

initializing destination conv1 repository
scanning source...
sorting...
converting...
3 1: add c
2 2: copy e from a, change b
1 4: merge 2 and 3, copy d from b
0 5: change a
o  3 5: change a files: a
|
o  2 4: merge 2 and 3, copy d from b files: a d e
|
o  1 2: copy e from a, change b files: b e
|
o  0 1: add c files: a b c

changeset:   2:30bab836cd67
user:        test
date:        Thu Jan 01 00:00:04 1970 +0000
summary:     4: merge 2 and 3, copy d from b

changeset:   1:15b8362bc103
user:        test
date:        Thu Jan 01 00:00:02 1970 +0000
summary:     2: copy e from a, change b

changeset:   2:30bab836cd67
user:        test
date:        Thu Jan 01 00:00:04 1970 +0000
summary:     4: merge 2 and 3, copy d from b

a 
a 
a 
b 
b 
initializing destination conv4 repository
scanning source...
sorting...
converting...
1 4: merge 2 and 3, copy d from b
0 5: change a
o  1 5: change a files: a
|
o  0 4: merge 2 and 3, copy d from b files: a b c d e

5 files updated, 0 files merged, 0 files removed, 0 files unresolved
a 
a 
a 
b 
b 







-----Original Message-----
From: Matt Mackall [mailto:mpm at selenic.com]
Sent: Mittwoch, 20. April 2011 16:53
To: Friedrich, Anna-Christina
Cc: mercurial-devel at selenic.com
Subject: Re: Windows Tests

On Wed, 2011-04-20 at 15:53 +0200, Friedrich, Anna-Christina wrote:
> As you see, we cannot use the Testing Plan, because of the required environment for testing.
> Are you interested in integrating those batch files and therefore adjust the mentioned files?

Yes, interested. You should send along a sample converted script for discussion.

--
Mathematics is the supreme nostalgia of our time.


---
This communication contains confidential information. If you are not the intended recipient please return this email to the sender and delete it from your records.

Diese Nachricht enthält vertrauliche Informationen. Sollten Sie nicht der beabsichtigte Empfänger dieser E-mail sein, senden Sie bitte diese an den Absender zurück und löschen Sie die E-mail aus Ihrem System.


More information about the Mercurial-devel mailing list