Skip to content

Increase unit test for pkg/generate/app #3016

Closed

Description

@soltysh

Currently the coverage for pkg/generate/app where the entire generation is done is:

ok      github.com/openshift/origin/pkg/generate/app    0.120s  coverage: 21.0% of statements

We should increase that number significantly to simplify the dev process of this portion of the code.

@Kargakis @csrwng fyi

Activity

  1. 0xmichalis commented on Jun 10, 2015

    @0xmichalis
    Contributor

    Agreed. Actually we will need to increase test coverage for the whole OpenShift:)

    Wait until at least @fabianofranz's changes in new-app land for this.

  2. modified the milestone: 1.1.0 on Jun 17, 2015
  3. modified the milestone: 1.1.0 on Oct 26, 2015
  4. bparees commented on Apr 25, 2017

    @bparees
    Contributor

    to be fair we have a good bit of coverage for this in end to end tests.

  5. soltysh commented on Apr 25, 2017

    @soltysh
    ContributorAuthor

    end to end is heavier to run, we should use unit/integration where possible.

  6. bparees commented on Apr 25, 2017

    @bparees
    Contributor

    end to end is heavier to run, we should use unit/integration where possible.

    i don't agree w/ the absolute nature of this position. unit tests tend to be harder to write (and sometimes harder to maintain) than end to end tests since they are so closely tied to the implementation. and for the most part you're not sitting waiting for the tests to run, they're running in a PR while you're doing something else.

    They each have their place, no doubt, but i don't think you can make a blanket statement that unit tests should be preferred in all cases.

  7. soltysh commented on Apr 25, 2017

    @soltysh
    ContributorAuthor

    I agree that each component has to be tested on every possible level, just to make sure it is working as expected (the more tests the better). Each of these tests look at different aspects of how things are working, that's what I wanted to say. But again, for things that can be added as unit tests I would prefer to see them tested. end-to-end are verbose but we will never create such a good coverage with end-to-end like you might have with table testing in unit. Or if you do it'll be a killer for our test and merge queue.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions