Deleted all references to PageRenderer from PageSet selectors; using wiki_references instead

This commit is contained in:
Alexey Verkhovsky 2005-09-11 08:05:19 +00:00
parent bec3c98227
commit 541a5d3994
7 changed files with 16 additions and 13 deletions

View file

@ -7,7 +7,7 @@ require 'admin_controller'
class AdminController; def rescue_action(e) logger.error(e); raise e end; end
class AdminControllerTest < Test::Unit::TestCase
fixtures :webs, :pages, :revisions, :system
fixtures :webs, :pages, :revisions, :system, :wiki_references
def setup
@controller = AdminController.new
@ -204,7 +204,6 @@ class AdminControllerTest < Test::Unit::TestCase
assert_equal page_order, @web.select.sort,
"Pages are not as expected: #{@web.select.sort.map {|p| p.name}.inspect}"
# Oak is now orphan, second pass should remove it
r = process('remove_orphaned_pages', 'web' => 'wiki1', 'system_password_orphaned' => 'pswd')
assert_redirected_to :controller => 'wiki', :web => 'wiki1', :action => 'list'

View file

@ -14,7 +14,7 @@ require 'zip/zipfilesystem'
class WikiController; def rescue_action(e) logger.error(e); raise e end; end
class WikiControllerTest < Test::Unit::TestCase
fixtures :webs, :pages, :revisions, :system
fixtures :webs, :pages, :revisions, :system, :wiki_references
def setup
@controller = WikiController.new

View file

@ -20,6 +20,9 @@ require 'url_generator'
Test::Unit::TestCase.use_instantiated_fixtures = false
Test::Unit::TestCase.fixture_path = File.dirname(__FILE__) + "/fixtures/"
# activate PageObserver
PageObserver.instance
class Test::Unit::TestCase
def create_fixtures(*table_names)
Fixtures.create_fixtures(File.dirname(__FILE__) + "/fixtures", table_names)

View file

@ -1,7 +1,7 @@
require File.expand_path(File.dirname(__FILE__) + '/../test_helper')
class WebTest < Test::Unit::TestCase
fixtures :webs, :pages, :revisions, :system
fixtures :webs, :pages, :revisions, :system, :wiki_references
def setup
@web = webs(:instiki)
@ -78,7 +78,7 @@ class WebTest < Test::Unit::TestCase
'This is an author page, it should not be an orphan',
Time.local(2004, 4, 4, 16, 50), 'AlexeyVerkhovsky', test_renderer)
self_linked = @web.add_page('SelfLinked',
'I am me SelfLinked and link to EverBeenInLove',
'I am SelfLinked and link to EverBeenInLove',
Time.local(2004, 4, 4, 16, 50), 'AnonymousCoward', test_renderer)
# page that links to itself, and nobody else links to it must be an orphan