@@ -115,7 +115,9 class RepositoryMercurialTest < ActiveSupport::TestCase | |||||
115 | assert_equal 'dir', entry.kind |
|
115 | assert_equal 'dir', entry.kind | |
116 | end |
|
116 | end | |
117 |
|
117 | |||
118 | def assert_entry |
|
118 | def assert_entry(is_short_scmid=true) | |
|
119 | hex = "0885933ad4f68d77c2649cd11f8311276e7ef7ce" | |||
|
120 | scmid = scmid_for_assert(hex, is_short_scmid) | |||
119 | ["README", "/README"].each do |path| |
|
121 | ["README", "/README"].each do |path| | |
120 | ["0", "0885933ad4f6", "0885933ad4f68d77c2649cd11f8311276e7ef7ce"].each do |rev| |
|
122 | ["0", "0885933ad4f6", "0885933ad4f68d77c2649cd11f8311276e7ef7ce"].each do |rev| | |
121 | entry = @repository.entry(path, rev) |
|
123 | entry = @repository.entry(path, rev) | |
@@ -123,7 +125,7 class RepositoryMercurialTest < ActiveSupport::TestCase | |||||
123 | assert_equal "README", entry.path |
|
125 | assert_equal "README", entry.path | |
124 | assert_equal "file", entry.kind |
|
126 | assert_equal "file", entry.kind | |
125 | assert_equal '0', entry.lastrev.revision |
|
127 | assert_equal '0', entry.lastrev.revision | |
126 |
assert_equal |
|
128 | assert_equal scmid, entry.lastrev.identifier | |
127 | end |
|
129 | end | |
128 | end |
|
130 | end | |
129 | ["sources", "/sources", "/sources/"].each do |path| |
|
131 | ["sources", "/sources", "/sources/"].each do |path| | |
@@ -141,14 +143,14 class RepositoryMercurialTest < ActiveSupport::TestCase | |||||
141 | assert_equal "sources/watchers_controller.rb", entry.path |
|
143 | assert_equal "sources/watchers_controller.rb", entry.path | |
142 | assert_equal "file", entry.kind |
|
144 | assert_equal "file", entry.kind | |
143 | assert_equal '0', entry.lastrev.revision |
|
145 | assert_equal '0', entry.lastrev.revision | |
144 |
assert_equal |
|
146 | assert_equal scmid, entry.lastrev.identifier | |
145 | end |
|
147 | end | |
146 | end |
|
148 | end | |
147 | end |
|
149 | end | |
148 | private :assert_entry |
|
150 | private :assert_entry | |
149 |
|
151 | |||
150 | def test_entry_short_id |
|
152 | def test_entry_short_id | |
151 | assert_entry |
|
153 | assert_entry(true) | |
152 | end |
|
154 | end | |
153 |
|
155 | |||
154 | def test_fetch_changesets_from_scratch |
|
156 | def test_fetch_changesets_from_scratch |
General Comments 0
You need to be logged in to leave comments.
Login now