Changesets can be listed by changeset number.
The Git repository is here.
- Revision:
- 15
- Log:
Attempt to update Typo to a Typo SVN HEAD release from around the
time the prototype installation was set up on the RISC OS Open Limited
web site. Timestamps place this at 04-Jul so a revision from 05-Jul or
earlier was pulled and copied over the 2.6.0 tarball stable code.
- Author:
- adh
- Date:
- Sat Jul 22 23:27:35 +0100 2006
- Size:
- 1528 Bytes
1 | require File.dirname(__FILE__) + '/../../test_helper' |
2 | require 'admin/blacklist_controller' |
3 | |
4 | # Re-raise errors caught by the controller. |
5 | class Admin::BlacklistController; def rescue_action(e) raise e end; end |
6 | |
7 | class Admin::BlacklistControllerTest < Test::Unit::TestCase |
8 | fixtures :blacklist_patterns, :users |
9 | |
10 | def setup |
11 | @controller = Admin::BlacklistController.new |
12 | @request = ActionController::TestRequest.new |
13 | @response = ActionController::TestResponse.new |
14 | |
15 | @request.session = { :user => users(:tobi) } |
16 | end |
17 | |
18 | def test_index |
19 | get :index |
20 | assert_rendered_file 'list' |
21 | end |
22 | |
23 | def test_list |
24 | get :list |
25 | assert_rendered_file 'list' |
26 | assert_template_has 'blacklist_patterns' |
27 | end |
28 | |
29 | def test_create |
30 | num_blacklist_patterns = BlacklistPattern.find_all.size |
31 | |
32 | post :new, 'blacklist_pattern' => { } |
33 | assert_redirected_to :action => 'list' |
34 | |
35 | assert_equal num_blacklist_patterns + 1, BlacklistPattern.find_all.size |
36 | end |
37 | |
38 | def test_edit |
39 | get :edit, 'id' => 1 |
40 | assert_rendered_file 'edit' |
41 | assert_template_has 'blacklist_pattern' |
42 | assert_valid_record 'blacklist_pattern' |
43 | end |
44 | |
45 | def test_update |
46 | post :edit, 'id' => 1 |
47 | assert_redirected_to :action => 'list' |
48 | end |
49 | |
50 | def test_destroy |
51 | assert_not_nil BlacklistPattern.find(1) |
52 | |
53 | get :destroy, 'id' => 1 |
54 | assert_success |
55 | |
56 | post :destroy, 'id' => 1 |
57 | assert_redirected_to :action => 'list' |
58 | |
59 | assert_raise(ActiveRecord::RecordNotFound) { |
60 | blacklist_pattern = BlacklistPattern.find(1) |
61 | } |
62 | end |
63 | end |