Skip to main content
aboutsummaryrefslogtreecommitdiffstats
blob: 5f619a37590f75bdbf6a34331bf3234f1d07de3d (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
/*******************************************************************************
 * Copyright (c) 2000, 2016 IBM Corporation and others.
 * All rights reserved. This program and the accompanying materials
 * are made available under the terms of the Eclipse Public License v1.0
 * which accompanies this distribution, and is available at
 * http://www.eclipse.org/legal/epl-v10.html
 *
 * Contributors:
 *     IBM Corporation - initial API and implementation
 *     Red Hat Inc. - Adapt to JUnit 4.
 *******************************************************************************/
package org.eclipse.swt.tests.junit;

import static org.junit.Assert.assertNotNull;
import static org.junit.Assert.assertTrue;

import org.eclipse.swt.accessibility.AccessibleTextEvent;
import org.eclipse.swt.widgets.Shell;
import org.junit.After;
import org.junit.Before;
import org.junit.Test;

/**
 * Automated Test Suite for class org.eclipse.swt.accessibility.AccessibleTextEvent
 *
 * @see org.eclipse.swt.accessibility.AccessibleTextEvent
 */
public class Test_org_eclipse_swt_accessibility_AccessibleTextEvent {

@Before
public void setUp() {
	shell = new Shell();
}

@After
public void tearDown() {
	shell.dispose();
}

@Test
public void test_ConstructorLjava_lang_Object() {
	// The source object should be a widget's accessible.
	AccessibleTextEvent event = new AccessibleTextEvent(shell.getAccessible());
	assertNotNull(event);
	
	// Test with some other object also.
	event = new AccessibleTextEvent(Integer.valueOf(5));
	assertNotNull(event);
}

@Test
public void test_toString() {
	AccessibleTextEvent event = new AccessibleTextEvent(shell.getAccessible());
	assertNotNull(event.toString());
	assertTrue(event.toString().length() > 0);
}
/* custom */
public Shell shell;
}

Back to the top