--- a/mercurial/HGTests.st Thu Mar 07 10:29:56 2013 +0000
+++ b/mercurial/HGTests.st Fri Mar 08 20:04:25 2013 +0000
@@ -573,6 +573,21 @@
"Created: / 27-11-2012 / 21:34:48 / Jan Vrany <jan.vrany@fit.cvut.cz>"
!
+test_heads_02
+ "
+ Test listing repository heads on an emptu repository
+ "
+
+ | repo heads |
+
+ repo := self repositoryNamed:'test_repo_empty' init: true.
+ heads := repo heads.
+
+ self assert: heads isEmpty.
+
+ "Created: / 08-03-2013 / 19:33:03 / Jan Vrany <jan.vrany@fit.cvut.cz>"
+!
+
test_remotes_01
"
Tests listing og repository remotes (upstream repos)
@@ -921,6 +936,34 @@
'.
"Created: / 05-12-2012 / 20:00:49 / Jan Vrany <jan.vrany@fit.cvut.cz>"
+!
+
+test_wc_03a
+
+ "
+ Test HGWorkingCopy>>changeset/changesetId on
+ an empty repository
+ "
+
+ | repo wc |
+
+ repo := self repositoryNamed:'test_repo_empty' init: true.
+ "
+ UserPreferences fileBrowserClass openOn: repo directory.
+ "
+ wc := repo workingCopy.
+ self assert: (wc path / '.hg' / 'dirstate') exists not.
+ self assert: wc changesetId = HGChangesetId null.
+ self assert: wc changeset = HGChangeset null.
+
+ ( wc / 'a.txt' ) writingFileDo:[:s|s nextPutAll: 'a'].
+ ( wc / 'a.txt' ) track.
+
+ self assert: (wc path / '.hg' / 'dirstate') exists.
+ self assert: wc changesetId = HGChangesetId null.
+ self assert: wc changeset = HGChangeset null.
+
+ "Created: / 08-03-2013 / 19:49:31 / Jan Vrany <jan.vrany@fit.cvut.cz>"
! !
!HGTests class methodsFor:'documentation'!