<?xml version="1.0" encoding="UTF-8"?>
<?eclipse version="3.0"?>
<plugin
   id="org.rubypeople.rdt.testunit"
   name="%pluginName"
   version="0.8.0.604272100PRD"
   provider-name="%providerName"
   class="org.rubypeople.rdt.testunit.TestunitPlugin">

   <runtime>
      <library name="testunit.jar">
         <export name="*"/>
      </library>
   </runtime>

   <requires>
      <import plugin="org.eclipse.ui"/>
      <import plugin="org.eclipse.core.runtime"/>
      <import plugin="org.eclipse.debug.core"/>
      <import plugin="org.eclipse.debug.ui"/>
      <import plugin="org.rubypeople.rdt.launching"/>
      <import plugin="org.rubypeople.rdt.core"/>
      <import plugin="org.eclipse.core.resources"/>
      <import plugin="org.rubypeople.rdt.ui"/>
      <import plugin="org.rubypeople.rdt.debug.ui"/>
      <import plugin="org.eclipse.ui.workbench.texteditor"/>
      <import plugin="org.eclipse.text"/>
   </requires>

   <extension-point id="internalTestRunTabs" name="%testRunTabs.name" schema="schema/internal-testRunTabs.exsd"/>

   <extension point="org.rubypeople.rdt.testunit.internalTestRunTabs">
      <testRunTab class="org.rubypeople.rdt.testunit.views.FailureTab"/>
      <testRunTab class="org.rubypeople.rdt.testunit.views.TestHierarchyTab"/>
   </extension>
   <extension
         point="org.eclipse.ui.views">
      <view
            name="Test::Unit"
            icon="icons/full/eview16/testunit.gif"
            category="org.rubypeople.rdt.ui.ruby"
            class="org.rubypeople.rdt.testunit.views.TestUnitView"
            id="org.rubypeople.rdt.testunit.views.TestUnitView">
      </view>
   </extension>
   <extension
         point="org.eclipse.ui.perspectiveExtensions">
      <perspectiveExtension
            targetID="org.rubypeople.rdt.ui.PerspectiveRuby">
         <viewShortcut id="org.rubypeople.rdt.testunit.views.TestUnitView"/> 
         <view
               relative="org.eclipse.ui.views.ContentOutline"
               relationship="stack"
               id="org.rubypeople.rdt.testunit.views.TestUnitView">
         </view>
      </perspectiveExtension>
   </extension>
   <extension
         point="org.eclipse.debug.ui.launchShortcuts">
      <shortcut
            label="%TestUnitShortcut.label"
            icon="icons/full/obj16/tulaunch.gif"
            helpContextId="org.rubypeople.rdt.testunit.launch_shortcut"
            class="org.rubypeople.rdt.testunit.launcher.TestUnitLaunchShortcut"
            modes="run,debug"
            id="org.rubypeople.rdt.testunit.testunitShortcut">
         <contextualLaunch>
            <enablement>
               <with
                     variable="selection">
                  <count
                        value="1">
                  </count>
                  <iterate>
                     <or>
                        <test
                              property="org.eclipse.debug.ui.matchesPattern"
                              value="*.rb">
                        </test>
                        <test
                              property="org.eclipse.debug.ui.matchesPattern"
                              value="*.rbw">
                        </test>
                        <test
                              property="org.eclipse.debug.ui.matchesPattern"
                              value="*.cgi">
                        </test>
                     </or>
                  </iterate>
               </with>
            </enablement>
         </contextualLaunch>
         <perspective
               id="org.rubypeople.rdt.ui.PerspectiveRuby">
         </perspective>
      </shortcut>
   </extension>
   <extension
         point="org.eclipse.debug.core.launchConfigurationTypes">
      <launchConfigurationType
            name="%LaunchConfigurationTypeTestUnit.name"
            delegate="org.rubypeople.rdt.testunit.launcher.TestUnitLaunchConfigurationDelegate"
            modes="run,debug"
            id="org.rubypeople.rdt.testunit.launchconfig">
         <fileExtension
               default="false"
               extension="rb">
         </fileExtension>
         <fileExtension
               default="false"
               extension="rbw">
         </fileExtension>
      </launchConfigurationType>
   </extension>
   <extension
         point="org.eclipse.debug.ui.launchConfigurationTypeImages">
      <launchConfigurationTypeImage
            icon="icons/full/obj16/tulaunch.gif"
            configTypeID="org.rubypeople.rdt.testunit.launchconfig"
            id="org.rubypeople.rdt.debug.ui.LaunchConfigurationTypeImageTestUnit">
      </launchConfigurationTypeImage>
   </extension>
   <extension
         point="org.eclipse.debug.ui.launchConfigurationTabGroups">
      <launchConfigurationTabGroup
            type="org.rubypeople.rdt.testunit.launchconfig"
            helpContextId="org.rubypeople.rdt.testunit.testunit_tab_group"
            class="org.rubypeople.rdt.testunit.launcher.TestUnitTabGroup"
            id="org.rubypeople.rdt.testunit.launchConfigurationTabGroup.testunit">
         <launchMode
               perspective="org.eclipse.debug.ui.DebugPerspective"
               description="%TestUnitTabGroupDescription.debug"
               mode="debug">
         </launchMode>
         <launchMode
               description="%TestUnitTabGroupDescription.run"
               mode="run">
         </launchMode>
      </launchConfigurationTabGroup>
   </extension>
   <extension
         point="org.eclipse.ui.commands">
      <command
            name="%TestUnitShortcut.description.run"
            description="%TestUnitShortcut.description.run"
            categoryId="org.eclipse.debug.ui.category.run"
            id="org.rubypeople.rdt.testunit.testunitShortcut.run">
      </command>
      <command
            name="%TestUnitShortcut.description.debug"
            description="%TestUnitShortcut.description.debug"
            categoryId="org.eclipse.debug.ui.category.run"
            id="org.rubypeople.rdt.testunit.testunitShortcut.debug">
      </command>
   </extension>
   <extension point="org.eclipse.ui.bindings">
      <key
            sequence="M3+M2+D U"
            commandId="org.rubypeople.rdt.testunit.testunitShortcut.debug"
            schemeId="org.eclipse.ui.defaultAcceleratorConfiguration"/>
      <key
            sequence="M3+M2+X U"
            commandId="org.rubypeople.rdt.testunit.testunitShortcut.run"
            schemeId="org.eclipse.ui.defaultAcceleratorConfiguration"/>
   </extension>
</plugin>
