Coder Social home page Coder Social logo

autotest/restart doesn't work about zentest HOT 7 CLOSED

seattlerb avatar seattlerb commented on August 19, 2024
autotest/restart doesn't work

from zentest.

Comments (7)

zenspider avatar zenspider commented on August 19, 2024

What's the output of autotest -v in that project?

from zentest.

semaperepelitsa avatar semaperepelitsa commented on August 19, 2024

No tests matched .autotest
No tests matched .rbenv-version
/Users/sema/.rbenv/versions/1.9.3-p0/bin/ruby -I.:lib:test -rubygems -e "%w[test/unit test/test_foo.rb].each { |f| require f }"
Run options: 

# Running tests:

.

Finished tests in 0.000931s, 1074.1139 tests/s, 0.0000 assertions/s.

1 tests, 0 assertions, 0 failures, 0 errors, 0 skips

After touch .autotest

{".autotest"=>2012-03-30 22:39:07 +0800}
No tests matched .autotest
{".autotest"=>2012-03-30 22:39:07 +0800}
No tests matched .autotest

from zentest.

zenspider avatar zenspider commented on August 19, 2024

So, I just did the following:

% sow blah
% cd blah
% emacs Rakefile # added: dependency "ZenTest", "~> 4.8", :developer
% rake           # to get all deps isolated
% GEM_PATH=tmp/isolate/ruby-1.8 tmp/isolate/ruby-1.8/bin/autotest -v

I added ZenTest just so I could have a local copy to hack on instead of dealing with load path stuffs. Once running, editing .autotest restarted autotest just fine.

The contents of my .autotest:

require "autotest/restart"

Autotest.add_hook :initialize do |at|
  at.testlib = "minitest/autorun"
  at.add_exception "tmp"
end

So maybe autotest/fsevent is messing things up. Comment that out and try again?

from zentest.

semaperepelitsa avatar semaperepelitsa commented on August 19, 2024

It works the same way without autotest/fsevent. I will try to repeat your steps exactly.

from zentest.

zenspider avatar zenspider commented on August 19, 2024

Any luck?

from zentest.

semaperepelitsa avatar semaperepelitsa commented on August 19, 2024

I have not been able to setup an isolated project using hoe. It uses system rubygems and does not create tmp/isolate directory. You probably have some global settings that allow you to do so. I have created a repo with just ZenTest & Isolate: https://github.com/semaperepelitsa/autotest-restart-bug.

rake isolate:sh
autotest -v
touch .autotest # in another terminal

And it outputs

{".autotest"=>2012-05-22 14:26:52 +0800}
No tests matched .autotest
{".autotest"=>2012-05-22 14:26:52 +0800}
No tests matched .autotest

touch test/test_foo.rb runs the test fine.

Can you clone the repo and reproduce my steps?

from zentest.

zenspider avatar zenspider commented on August 19, 2024

I don't have any global settings or anything fancy going on. I just have hoe, isolate, and rake installed.

I was able to reproduce your error, but only under 1.9. Enumerable#select on a Hash instance on 1.9 returns a Hash, as a result my flatten wasn't flattening. I've fixed it by getting rid of my splat arg to the block.

from zentest.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.