Uploaded image for project: 'Apache YuniKorn'
  1. Apache YuniKorn
  2. YUNIKORN-601

KubeClient mock does not allow failure tests

    XMLWordPrintableJSON

Details

    Description

      The way the NewKubeClientMock() works is to setup functions fo all actions that always succeed. That prevents any error handling to be tested in the unit tests that require failure for a delete, update or add.

      We should be able to test failure paths also when using the mock.

      The fact that we cannot test failure paths with the mock allowed YUNIKORN-600 to go undetected.

      Attachments

        Issue Links

          Activity

            People

              steinsgateted Ted Lin
              wilfreds Wilfred Spiegelenburg
              Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: