Skip to content
Permalink
Browse files
[Truffle] JT: allow arbitrary paths for jt test.
* So for instance one can use ":core".
  • Loading branch information
eregon committed Jan 9, 2015
1 parent bf71e56 commit 83b4dba5633a43740aaf0ea789688876e3f1a57a
Showing 1 changed file with 5 additions and 10 deletions.
@@ -60,21 +60,16 @@ def rebuild
build
end

def test(path=nil, *args)
if path == nil
mspec 'run', '--excl-tag', 'fails', ':language', ':core', *args
elsif path.start_with? 'spec/ruby'
mspec 'run', '--excl-tag', 'fails', path, *args
else
raise ArgumentError, "don't know how to test #{path}"
end
def test(*args)
args = [':language', ':core'] if args.empty?
mspec 'run', '--excl-tag', 'fails', *args
end

def tag(path)
def tag(path, *args)
mspec 'tag', '--add', 'fails', '--fail', path, *args
end

def untag(path)
def untag(path, *args)
puts
puts "WARNING: untag is currently not very reliable - run `jt test #{path}` after and manually annotate any new failures"
puts

5 comments on commit 83b4dba

@chrisseaton
Copy link
Contributor

@chrisseaton chrisseaton commented on 83b4dba Jan 9, 2015

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The idea was that in the future we would also run MRI's tests - and to tell the difference between them to run the correct command we would look at the start of the path - but it doesn't matter for now.

@eregon
Copy link
Member Author

@eregon eregon commented on 83b4dba Jan 9, 2015

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I see, I think we can still make the difference (we would need to parse *args).
Having a different command might also be an idea.

@chrisseaton
Copy link
Contributor

@chrisseaton chrisseaton commented on 83b4dba Jan 9, 2015

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ah but reading the name of the commit, I see the utility - running :core or :language is a good idea

@chrisseaton
Copy link
Contributor

@chrisseaton chrisseaton commented on 83b4dba Jan 9, 2015

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We should also maybe define a :fast_core that doesn't include things that have to shell out

@eregon
Copy link
Member Author

@eregon eregon commented on 83b4dba Jan 9, 2015

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yeah, that would be interesting indeed for quickly testing invasive changes.

Please sign in to comment.