Uploaded image for project: 'Jenkins'
  1. Jenkins
  2. JENKINS-34428

workflow-cps-global-lib: inheritance (extends) not working

    • Icon: Bug Bug
    • Resolution: Unresolved
    • Icon: Major Major
    • workflow-cps-plugin
    • None

      I'm not able to use inheritance in Workflow Global Library code.

      Here is a simple example to demonstrate:

      // src/com/test/MyMap.groovy
      
      package com.test
      
      class MyMap extends HashMap {
      
          def test(String property) {
              super.get(property)
          }
      }
      

          [JENKINS-34428] workflow-cps-global-lib: inheritance (extends) not working

          Martin Vehovsky created issue -
          R. Tyler Croy made changes -
          Workflow Original: JNJira [ 170541 ] New: JNJira + In-Review [ 183948 ]
          Andrew Bayer made changes -
          Component/s New: pipeline-general [ 21692 ]
          Andrew Bayer made changes -
          Component/s Original: workflow-plugin [ 18820 ]
          Jesse Glick made changes -
          Component/s New: workflow-cps-plugin [ 21713 ]
          Component/s Original: pipeline [ 21692 ]
          Andrew Bayer made changes -
          Assignee Original: Jesse Glick [ jglick ] New: Andrew Bayer [ abayer ]
          Andrew Bayer made changes -
          Link New: This issue is duplicated by JENKINS-47143 [ JENKINS-47143 ]
          Andrew Bayer made changes -
          Link New: This issue is duplicated by JENKINS-47355 [ JENKINS-47355 ]
          Reinhold Füreder made changes -
          Link New: This issue is related to JENKINS-50731 [ JENKINS-50731 ]
          Reinhold Füreder made changes -
          Link New: This issue is related to JENKINS-50736 [ JENKINS-50736 ]
          Bruno Conrado Santos made changes -
          Assignee Original: Andrew Bayer [ abayer ] New: Bruno Conrado Santos [ brunocconrado ]

            Unassigned Unassigned
            vehovmar Martin Vehovsky
            Votes:
            17 Vote for this issue
            Watchers:
            20 Start watching this issue

              Created:
              Updated: