Commit 7ebca409 authored by Nikolay Sivov's avatar Nikolay Sivov Committed by Alexandre Julliard

comctl32/updown: Additional test for display base.

parent 4efa9f5e
......@@ -472,6 +472,7 @@ static void test_updown_base(void)
{
HWND updown;
int r;
CHAR text[10];
updown = create_updown_control(0);
......@@ -508,6 +509,25 @@ static void test_updown_base(void)
ok_sequence(sequences, UPDOWN_SEQ_INDEX, test_updown_base_seq, "test updown base", FALSE);
DestroyWindow(updown);
/* switch base with buddy attached */
updown = create_updown_control(UDS_SETBUDDYINT);
r = SendMessage(updown, UDM_SETPOS32, 0, 10);
expect(50, r);
GetWindowTextA(edit, text, sizeof(text)/sizeof(CHAR));
ok(lstrcmpA(text, "10") == 0, "Expected '10', got '%s'\n", text);
r = SendMessage(updown, UDM_SETBASE, 16, 0);
expect(10, r);
GetWindowTextA(edit, text, sizeof(text)/sizeof(CHAR));
/* FIXME: currently hex output isn't properly formatted, but for this
test only change from initial text matters */
todo_wine ok(lstrcmpA(text, "10") != 0, "Expected '0x000A', got '%s'\n", text);
DestroyWindow(updown);
}
static void test_updown_unicode(void)
......@@ -569,6 +589,10 @@ static void test_UDS_SETBUDDYINT(void)
CHAR text[10];
BOOL b;
/* cleanup buddy */
text[0] = '\0';
SetWindowTextA(edit, text);
/* creating without UDS_SETBUDDYINT */
updown = create_updown_control(0);
/* try to set UDS_SETBUDDYINT after creation */
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment