8000 runs all tests which start with same name · Issue #21 · judofyr/minitest-line · GitHub
[go: up one dir, main page]

Skip to content

runs all tests which start with same name #21

Open

Description

@fran-worley

say I have the following specs:

describe 'MyTests' do
  context 'when can view profile' do
    it 'should run'
  end

  context 'when can view profile settings' do
    it 'should not run'
  end
end

If I use minitest line to run all tests in the first context (i.e: when can view profile) then it will also run the second as the names start the same when really it should only run the tests inside that specific context block.

Activity

  1. grosser commented on Dec 28, 2018

    @grosser
    Contributor

    the matching of describe blocks works by building a regex that matches the describe name, since that's the only input minitest filter supports ... so a workaround might be to build a list of all possible test names instead ... not sure if that's supported in minitest core, but worth a try, best first look into how options[:filter] is handled in minitest and how we could make it do what we want

  2. fran-worley commented on Jan 3, 2019

    @fran-worley
    Author

    @grosser thanks for coming back to me so quickly and clarifying the position. I will endeavour to investigate but in all honestly I doubt I'll have much time in the next few weeks will raise a PR if I come up with anything worthwhile!

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

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions

      0