Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(65)

Side by Side Diff: third_party/xdg-utils/tests/xdg-icon-resource/t.icon_system_uninstall

Issue 151098: Patch from mdm@google.com... (Closed) Base URL: svn://chrome-svn/chrome/trunk/deps/
Patch Set: Created 11 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
Property Changes:
Name: svn:executable
+ *
OLDNEW
(Empty)
1 #!/bin/bash
2
3 ## Include utility functions.
4 . "$XDG_TEST_DIR/include/testassertions.sh"
5 . "$XDG_TEST_DIR/include/testcontrol.sh"
6
7 ## Test function
8 test_icon_system_uninstall() {
9 test_start "$FUNCNAME: verify $ICON is uninstalled correctly with --mode system"
10
11 ## Begin the test.
12 systempath="${XDG_DATA_DIRS-/usr/local/share:/usr/share}:/usr/share/pixmaps"
13
14 # Dependencies section
15 test_init
16
17 require_root
18 set_no_display
19
20 use_file "$XDG_TEST_DIR/icons/$ICON" ICONFILE
21 assert_file "$ICONFILE"
22
23 # Verify the test icon is not installed already.
24 assert_exit 0 xdg-icon-resource install --mode system --size "$SIZE" "$ICONFILE"
25 assert_file_in_path "$ICONFILE" "$systempath"
26
27 # Test steps section
28 test_procedure
29
30 assert_exit 0 xdg-icon-resource uninstall --mode system --size "$SIZE" "$ICONFIL E"
31 assert_nostdout
32 assert_nostderr
33
34 assert_file_not_in_path "$ICONFILE" "$systempath"
35
36 test_result
37 }
38
39 repeat_test test_icon_system_uninstall 2 ICON SIZE 'red-16.png' 'red-22.png' 're d-24.png' 'red-32.png' 16 22 24 32
40 repeat_test test_icon_system_uninstall 2 ICON SIZE 'red-48.png' 'red-64.png' 're d-128.png' 48 64 128
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698