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

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

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
6 . "$XDG_TEST_DIR/include/testcontrol.sh"
7
8 ## Test function
9 test_icon_user_install() {
10 test_start "$FUNCNAME: verify $ICON is installed correctly"
11
12 ## Begin the test.
13 userpath="$HOME/.icons:$HOME/.local:$XDG_DATA_HOME"
14
15 # Dependencies section
16 test_init
17
18 set_no_display
19 use_file "$XDG_TEST_DIR/icons/$ICON" ICONFILE
20 assert_file "$ICONFILE"
21
22 # Verify the test icon is not installed already.
23 assert_file_not_in_path "$ICONFILE" "$userpath"
24
25 # Test steps section
26 test_procedure
27
28 assert_exit 0 xdg-icon-resource install --mode user --size "$SIZE" "$ICONFILE"
29 assert_nostdout
30 assert_nostderr
31
32 assert_file_in_path "$ICONFILE" "$userpath"
33
34 xdg-icon-resource uninstall --mode user --size "$SIZE" "$ICONFILE"
35
36 test_result
37 }
38
39 repeat_test test_icon_user_install 2 ICON SIZE 'red-16.png' 'red-22.png' 'red-24 .png' 'red-32.png' 16 22 24 32
40 repeat_test test_icon_user_install 2 ICON SIZE 'red-48.png' 'red-64.png' 'red-12 8.png' 48 64 128
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698