mordaroso / guard-motion Goto Github PK
View Code? Open in Web Editor NEWGuard::Motion automatically run your RubyMotion specs (much like autotest)
License: MIT License
Guard::Motion automatically run your RubyMotion specs (much like autotest)
License: MIT License
When I use guard-motion with the growl notifier for guard through the growl gem, I get the following error:
13:57:04 - ERROR - Error sending notification with growl: undefined method
type=' for #Growl::Base:0x007f9ca1033f00`
This appears to be caused by your supplying a :type option Notifier.notify in runner.rb:47; Notifier.notify passes that option on in the options hash to Notifier::Growl.notify (notifier.rb:171), which in turn passes it on to Growl::Base.new (growl.rb:90), which attempts to call self.type= (growl.rb:148), which doesn't exist.
As far as I can tell there is no need to pass a :type option, as Notifier.notify sets type information based on the :image option (notifier.rb:165). According to the RDoc for Guard::Notifier, the :image option is the intended way to specify a type.
Is there a way to get specs to load their dependencies automatically? For example, if I have:
class Foo
def self.hello
"hello"
end
end
describe Foo do
describe "#hello" do
it "returns hello" do
Foo.hello.should == "hello"
end
end
end
Is there a way to run guard so I don't have to explicitly require Foo
?
Hi, I'm receiving the following error when I run guard init
or guard init motion
.
ERROR - Could not load 'guard/motion' or '~/.guard/templates/motion' or find class Guard::Motion
My setup -
OS X Yosemite 10.10.1
Running Ruby 2.1.2 with RVM
Gemfile
source 'https://rubygems.org'
gem 'rake'
# Add your dependencies here:
gem 'cocoapods'
gem 'motion-cocoapods'
gem 'motion_model'
gem 'formotion'
gem 'json', '~> 1.8.1'
gem 'guard-motion'
gem 'rb-fsevent', :require => false
Rakefile
# -*- coding: utf-8 -*-
$:.unshift("/Library/RubyMotion/lib")
require 'motion/project/template/ios'
require 'motion-cocoapods'
require 'motion_model'
require 'guard/motion'
require 'formotion'
begin
require 'bundler'
Bundler.require
rescue LoadError
end
Motion::Project::App.setup do |app|
# Use `rake config' to see complete project settings.
app.name = 'SafeDate'
# iOS Specific config
app.icons = []
app.fonts = []
app.prerendered_icon = true
app.interface_orientations = [:portrait]
app.pods do
pod 'AFNetworking'
end
end
Hi, is it possible to run the spec tests on a device directly? So instead of calling:
Rake::Task["spec"].invoke
call it like this:
Rake::Task["spec:device"].invoke
Is something like this possible? I don't really know where to start, because I don't know where the App.config
is set.
Hi there,
Thanks for creating an official guard for RubyMotion. Unfortunately I am not able to get it working, as I get the following error:
Guard::Motion is running
Running all specs
rake aborted!
Don't know how to build task 'spec:specific'
Thanks!
Hi, I'm trying to use your gem but I'm having some trouble with it.
I've installed the gem guard-motion
. Now when I run guard init motion
I get the following:
guard init motion
11:46:00 - ERROR - Could not load 'guard/motion' or '~/.guard/templates/motion' or find class Guard::Motion
11:46:00 - ERROR - Error is: No such file or directory @ rb_sysopen - /Users/nandersen/.guard/templates/motion
This is my guardfile:
# A sample Guardfile
# More info at https://github.com/guard/guard#readme
## Uncomment and set this to only include directories you want to watch
directories %w(app lib spec) \
.select{|d| Dir.exists?(d) ? d : UI.warning("Directory #{d} does not exist")}
## Note: if you are using the `directories` clause above and you are not
## watching the project directory ('.'), then you will want to move
## the Guardfile to a watched dir and symlink it back, e.g.
#
# $ mkdir config
# $ mv Guardfile config/
# $ ln -s config/Guardfile .
#
# and, you'll have to watch "config/Guardfile" instead of "Guardfile"
It makes no difference if I comment the following lines or not:
directories %w(app lib spec) \
.select{|d| Dir.exists?(d) ? d : UI.warning("Directory #{d} does not exist")}
What am I doing wrong? Thanks!
If I have an empty specification in my test, then guard just "hangs" on it. It doesn't skip it, it simply just stops and I have to close my terminal window then. This would make it hang:
context "Correct password/email combination" do
before do
@login_email_input.text = "[email protected]"
@login_password_input.text = "demo1234"
controller.login do |block|
@block = block
resume
end
end
it "return true" do
wait_max(10) { @block.should.equal true }
end
# This makes guard hang
it "save slug"
end
Is this the intended behavior?
I'm using iTerm btw.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.