Rails4: scm: reload repository after destroying changesets in incremental fetch test
git-svn-id: http://svn.redmine.org/redmine/trunk@12472 e93f8b46-1217-0410-a6f0-8f06a7374b81
This commit is contained in:
parent
e9470e5585
commit
9cefc90b0b
|
@ -107,6 +107,7 @@ class RepositoryBazaarTest < ActiveSupport::TestCase
|
|||
# Remove changesets with revision > 5
|
||||
@repository.changesets.all.each {|c| c.destroy if c.revision.to_i > 2}
|
||||
@project.reload
|
||||
@repository.reload
|
||||
assert_equal 2, @repository.changesets.count
|
||||
|
||||
@repository.fetch_changesets
|
||||
|
|
|
@ -118,6 +118,7 @@ class RepositoryCvsTest < ActiveSupport::TestCase
|
|||
# Remove changesets with revision > 3
|
||||
@repository.changesets.all.each {|c| c.destroy if c.revision.to_i > 3}
|
||||
@project.reload
|
||||
@repository.reload
|
||||
assert_equal 3, @repository.changesets.count
|
||||
assert_equal %w|3 2 1|, @repository.changesets.all.collect(&:revision)
|
||||
|
||||
|
|
|
@ -81,6 +81,7 @@ class RepositoryDarcsTest < ActiveSupport::TestCase
|
|||
# Remove changesets with revision > 3
|
||||
@repository.changesets.all.each {|c| c.destroy if c.revision.to_i > 3}
|
||||
@project.reload
|
||||
@repository.reload
|
||||
assert_equal 3, @repository.changesets.count
|
||||
|
||||
@repository.fetch_changesets
|
||||
|
|
|
@ -104,6 +104,7 @@ class RepositoryMercurialTest < ActiveSupport::TestCase
|
|||
# Remove changesets with revision > 2
|
||||
@repository.changesets.all.each {|c| c.destroy if c.revision.to_i > 2}
|
||||
@project.reload
|
||||
@repository.reload
|
||||
assert_equal 3, @repository.changesets.count
|
||||
|
||||
@repository.fetch_changesets
|
||||
|
|
|
@ -77,6 +77,7 @@ class RepositorySubversionTest < ActiveSupport::TestCase
|
|||
# Remove changesets with revision > 5
|
||||
@repository.changesets.all.each {|c| c.destroy if c.revision.to_i > 5}
|
||||
@project.reload
|
||||
@repository.reload
|
||||
assert_equal 5, @repository.changesets.count
|
||||
|
||||
@repository.fetch_changesets
|
||||
|
|
Loading…
Reference in New Issue