| /* |
| * Copyright (c) 2003, 2004 IBM Corporation and others. |
| * All rights reserved. This program and the accompanying materials |
| * are made available under the terms of the Common Public License v1.0 |
| * which accompanies this distribution, and is available at |
| * http://www.eclipse.org/legal/cpl-v10.html |
| * |
| * Contributors: |
| * IBM - Initial API and implementation |
| * |
| * $Id: RedefinableElementImplTest.java,v 1.3 2004/05/20 03:03:32 khussey Exp $ |
| */ |
| package org.eclipse.uml2.impl.tests; |
| |
| import java.util.Iterator; |
| |
| import org.eclipse.uml2.Classifier; |
| import org.eclipse.uml2.RedefinableElement; |
| import org.eclipse.uml2.impl.RedefinableElementImpl; |
| |
| /** |
| * <!-- begin-user-doc --> |
| * A test case for the model object '<em><b>Redefinable Element</b></em>'. |
| * <!-- end-user-doc --> |
| * <p> |
| * The following features are tested: |
| * <ul> |
| * <li>{@link org.eclipse.uml2.impl.RedefinableElementImpl#getRedefinitionContexts() <em>Redefinition Context</em>}</li> |
| * </ul> |
| * </p> |
| * <p> |
| * The following operations are tested: |
| * <ul> |
| * <li>{@link org.eclipse.uml2.impl.RedefinableElementImpl#validateRedefinitionContextValid(EDiagnosticChain, EMap) <em>Validate Redefinition Context Valid</em>}</li> |
| * <li>{@link org.eclipse.uml2.impl.RedefinableElementImpl#validateRedefinitionConsistent(EDiagnosticChain, EMap) <em>Validate Redefinition Consistent</em>}</li> |
| * <li>{@link org.eclipse.uml2.impl.RedefinableElementImpl#isConsistentWith(RedefinableElement) <em>Is Consistent With</em>}</li> |
| * <li>{@link org.eclipse.uml2.impl.RedefinableElementImpl#isRedefinitionContextValid(RedefinableElement) <em>Is Redefinition Context Valid</em>}</li> |
| * <li>{@link org.eclipse.uml2.impl.RedefinableElementImpl#getRedefinedElements() <em>Get Redefined Elements</em>}</li> |
| * </ul> |
| * </p> |
| * @generated |
| */ |
| public abstract class RedefinableElementImplTest extends NamedElementImplTest { |
| |
| /** |
| * <!-- begin-user-doc --> |
| * <!-- end-user-doc --> |
| * @generated |
| */ |
| public static final String copyright = "Copyright (c) 2003, 2004 IBM Corporation and others."; //$NON-NLS-1$ |
| |
| /** |
| * Constructs a new Redefinable Element test case with the given name. |
| * <!-- begin-user-doc --> |
| * <!-- end-user-doc --> |
| * @generated |
| */ |
| public RedefinableElementImplTest(String name) { |
| super(name); |
| } |
| |
| /** |
| * Returns the fixture for this Redefinable Element test case. |
| * <!-- begin-user-doc --> |
| * <!-- end-user-doc --> |
| * @generated |
| */ |
| private RedefinableElementImpl getFixture() { |
| return (RedefinableElementImpl) fixture; |
| } |
| |
| /** |
| * Tests the '{@link org.eclipse.uml2.impl.RedefinableElementImpl#getRedefinitionContexts() <em>Redefinition Context</em>}' feature getter. |
| * <!-- begin-user-doc --> |
| * <!-- end-user-doc --> |
| * @see org.eclipse.uml2.impl.RedefinableElementImpl#getRedefinitionContexts() |
| * @generated |
| */ |
| public void testGetRedefinitionContextsGen() { |
| // TODO: implement this feature getter test method |
| } |
| |
| public void testGetRedefinitionContexts() { |
| testGetRedefinitionContextsGen(); |
| |
| setUpRedefinitionContexts(); |
| |
| for (Iterator redefinitionContexts = getFixture().getRedefinitionContexts().iterator(); redefinitionContexts.hasNext();) { |
| assertTrue(Classifier.class.isInstance(redefinitionContexts.next())); |
| } |
| } |
| |
| /** |
| * Tests the '{@link org.eclipse.uml2.impl.RedefinableElementImpl#validateRedefinitionContextValid(EDiagnosticChain, EMap) <em>Validate Redefinition Context Valid</em>}' operation. |
| * <!-- begin-user-doc --> |
| * <!-- end-user-doc --> |
| * @see org.eclipse.uml2.impl.RedefinableElementImpl#validateRedefinitionContextValid(EDiagnosticChain, EMap) |
| * @generated |
| */ |
| public void testValidateRedefinitionContextValid__EDiagnosticChain_EMap() { |
| // TODO: implement this operation test method |
| } |
| |
| /** |
| * Tests the '{@link org.eclipse.uml2.impl.RedefinableElementImpl#validateRedefinitionConsistent(EDiagnosticChain, EMap) <em>Validate Redefinition Consistent</em>}' operation. |
| * <!-- begin-user-doc --> |
| * <!-- end-user-doc --> |
| * @see org.eclipse.uml2.impl.RedefinableElementImpl#validateRedefinitionConsistent(EDiagnosticChain, EMap) |
| * @generated |
| */ |
| public void testValidateRedefinitionConsistent__EDiagnosticChain_EMap() { |
| // TODO: implement this operation test method |
| } |
| |
| /** |
| * Tests the '{@link org.eclipse.uml2.impl.RedefinableElementImpl#isConsistentWith(RedefinableElement) <em>Is Consistent With</em>}' operation. |
| * <!-- begin-user-doc --> |
| * <!-- end-user-doc --> |
| * @see org.eclipse.uml2.impl.RedefinableElementImpl#isConsistentWith(RedefinableElement) |
| * @generated |
| */ |
| public void testIsConsistentWith__RedefinableElement() { |
| // TODO: implement this operation test method |
| } |
| |
| /** |
| * Tests the '{@link org.eclipse.uml2.impl.RedefinableElementImpl#isRedefinitionContextValid(RedefinableElement) <em>Is Redefinition Context Valid</em>}' operation. |
| * <!-- begin-user-doc --> |
| * <!-- end-user-doc --> |
| * @see org.eclipse.uml2.impl.RedefinableElementImpl#isRedefinitionContextValid(RedefinableElement) |
| * @generated |
| */ |
| public void testIsRedefinitionContextValid__RedefinableElement() { |
| // TODO: implement this operation test method |
| } |
| |
| /** |
| * Tests the '{@link org.eclipse.uml2.impl.RedefinableElementImpl#getRedefinedElements() <em>Get Redefined Elements</em>}' getter operation. |
| * <!-- begin-user-doc --> |
| * <!-- end-user-doc --> |
| * @see org.eclipse.uml2.impl.RedefinableElementImpl#getRedefinedElements() |
| * @generated |
| */ |
| public void testGetRedefinedElementsGen() { |
| // TODO: implement this getter operation test method |
| } |
| |
| public void testGetRedefinedElements() { |
| testGetRedefinedElementsGen(); |
| |
| setUpRedefinedElements(); |
| |
| for (Iterator redefinedElements = getFixture().getRedefinedElements().iterator(); redefinedElements.hasNext();) { |
| assertTrue(RedefinableElement.class.isInstance(redefinedElements.next())); |
| } |
| } |
| |
| protected void setUpRedefinitionContexts() { |
| // do nothing |
| } |
| |
| protected void setUpRedefinedElements() { |
| // do nothing |
| } |
| |
| } //RedefinableElementImplTest |