/
TestConfigurator.java
82 lines (68 loc) · 2.9 KB
/
TestConfigurator.java
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
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
/*******************************************************************************
* Copyright (c) 2014 RCP Vision (http://www.rcp-vision.com) 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:
* Lorenzo Bettini - Initial contribution and API
*******************************************************************************/
package org.eclipse.emf.parsley.tests.swtbot.views;
import org.eclipse.emf.common.util.URI;
import org.eclipse.emf.ecore.EClass;
import org.eclipse.emf.parsley.config.Configurator;
import org.eclipse.emf.parsley.examples.library.EXTLibraryPackage;
import org.eclipse.emf.parsley.tests.swtbot.EmfParsleySWTBotAbstractTests;
/**
* A {@link Configurator} used in tests to provide the needed configurations for
* the views in this package.
*
* @author Lorenzo Bettini - Initial contribution and API
*
*/
public class TestConfigurator extends Configurator {
public URI resourceURI(TestSaveableTreeView requestor) {
return URI.createPlatformResourceURI(
EmfParsleySWTBotAbstractTests.MY_EXTLIBRARY_RELATIVE_PATH, true);
}
public URI resourceURI(TestSaveableTreeView2 requestor) {
return URI.createPlatformResourceURI(
EmfParsleySWTBotAbstractTests.MY2_EXTLIBRARY_RELATIVE_PATH, true);
}
public URI resourceURI(TestSaveableTreeViewWithColumns requestor) {
return URI.createPlatformResourceURI(
EmfParsleySWTBotAbstractTests.MY_EXTLIBRARY_RELATIVE_PATH, true);
}
public EClass eClass(TestSaveableTreeViewWithColumns requestor) {
return EXTLibraryPackage.Literals.WRITER;
}
public URI resourceURI(TestSaveableTreeViewWithSpecificColumns requestor) {
return URI.createPlatformResourceURI(
EmfParsleySWTBotAbstractTests.MY_EXTLIBRARY_RELATIVE_PATH, true);
}
public URI resourceURI(TestSaveableResourceTreeFormView requestor) {
return URI.createPlatformResourceURI(
EmfParsleySWTBotAbstractTests.MY_EXTLIBRARY_RELATIVE_PATH, true);
}
public EClass eClass(TestSaveableResourceTableView requestor) {
return EXTLibraryPackage.Literals.BOOK;
}
public URI resourceURI(TestSaveableResourceTableView requestor) {
return URI.createPlatformResourceURI(
EmfParsleySWTBotAbstractTests.MY_EXTLIBRARY_RELATIVE_PATH, true);
}
public EClass eClass(TestSaveableResourceTableFormView requestor) {
return EXTLibraryPackage.Literals.BOOK;
}
public URI resourceURI(TestSaveableResourceTableFormView requestor) {
return URI.createPlatformResourceURI(
EmfParsleySWTBotAbstractTests.MY_EXTLIBRARY_RELATIVE_PATH, true);
}
public EClass eClass(TestOnSelectionLibraryBooksTableView requestor) {
return EXTLibraryPackage.Literals.BOOK;
}
public EClass eClass(TestOnSelectionLibraryBooksTableFormView requestor) {
return EXTLibraryPackage.Literals.BOOK;
}
}