Here's some of our troubles:
* The "examples" directory -- to which the readme directs us -- has
two subdirectories, "html" and "ruby" which should really be named
"using a static suite" and "using a jasmine server", right? And in
fact they could be a single directory like you use for testing Jasmine
itself, containing both a static HTML file and the Ruby files.
* jasmine_spec.rb has all this saucelabs stuff all over the place
which is pretty confusing for people who are just trying to get things
going locally. It should be in a separate "using sauce labs" example
directory, or maybe just a howto or library.
* geminstaller fails to find ragaskar-jsdoc_helper and pivotal-
selenium-rc since github isn't serving gems any more. I guess I'll
have to go clone them and try to build gems and install them manually?
* jasmine_spec.rb also has a bug in it -- you need to specify
"localhost" to SeleniumRC::Server.new. This may be because you're
using github's pivotal-selenium-rc.
* Also there's a embarrassing bug in jasmine_runner.rb, repeated
several times in that file:
@browser = options[:browser] ? options[:browser].delete(:browser) :
'firefox'
should be
@browser = options[:browser] ? options.delete(:browser) : 'firefox'
* There's no documentation on how to include our app JS files when
using the server runner (vs. the html page runner). In the HTML suite
files there are <script> lines but where do I load the system under
test?
* Currently I can run the server and get some specs to execute in the
browser, but selenium freezes after bringing up the selenium status
window but before opening the actual runner. I'm thinking maybe this
will get better if I install the different selenium-rc gem...
I have several other questions but I'll wait until I get this running
first. :-)
Merry Christmas!
- Alex
My coworker and I just tried to install Jasmine in our Sinatra webapp
and encountered some serious problems with the documentation and code.
I'm sure Jasmine is awesome once you get it rolling but...
Here's some of our troubles:
* The "examples" directory -- to which the readme directs us -- has
two subdirectories, "html" and "ruby" which should really be named
"using a static suite" and "using a jasmine server", right? And in
fact they could be a single directory like you use for testing Jasmine
itself, containing both a static HTML file and the Ruby files.
* jasmine_spec.rb has all this saucelabs stuff all over the place
which is pretty confusing for people who are just trying to get things
going locally. It should be in a separate "using sauce labs" example
directory, or maybe just a howto or library.
* geminstaller fails to find ragaskar-jsdoc_helper and pivotal-
selenium-rc since github isn't serving gems any more. I guess I'll
have to go clone them and try to build gems and install them manually?
* jasmine_spec.rb also has a bug in it -- you need to specify
"localhost" to SeleniumRC::Server.new. This may be because you're
using github's pivotal-selenium-rc.
* Also there's a embarrassing bug in jasmine_runner.rb, repeated
several times in that file:
@browser = options[:browser] ? options[:browser].delete(:browser) :
'firefox'
should be
@browser = options[:browser] ? options.delete(:browser) : 'firefox'
* There's no documentation on how to include our app JS files when
using the server runner (vs. the html page runner). In the HTML suite
files there are <script> lines but where do I load the system under
test?
* Currently I can run the server and get some specs to execute in the
browser, but selenium freezes after bringing up the selenium status
window but before opening the actual runner. I'm thinking maybe this
will get better if I install the different selenium-rc gem...
I have several other questions but I'll wait until I get this running
first. :-)
Merry Christmas!
- Alex
--
You received this message because you are subscribed to the Google Groups "Jasmine" group.
To post to this group, send email to jasmi...@googlegroups.com.
To unsubscribe from this group, send email to jasmine-js+...@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/jasmine-js?hl=en.
>> * jasmine_spec.rb also has a bug in it -- you need to specify
>> "localhost" to SeleniumRC::Server.new. This may be because you're
>> using github's pivotal-selenium-rc.
Looks like you snuck in and fixed this last night. :-)
>> * Currently I can run the server and get some specs to execute in the
>> browser, but selenium freezes after bringing up the selenium status
>> window but before opening the actual runner. I'm thinking maybe this
>> will get better if I install the different selenium-rc gem...
I think that this was caused by the dreaded dylib problem -- Selenium
poisoning makes wild elemental animals fight (Fire Fox vs. Snow
Leopard)... Here's the fix:
cp /usr/lib/libsqlite3.dylib
/Applications/Firefox.app/Contents/MacOS/libsqlite3.dylib
(Make sure not to do that in the wrong direction or you'll hose PAM
and not be able to sudo or log in. I proved this empirically. :-P --
leading to my next tip, "Hold down Command-S at startup to boot into
single user mode.")
> It's possible to pass a list
> of app files to the ruby server as "spec_helpers". On the other hand, some
> people have used jasmine.include() to retrieve app files in a spec_helper.js
> file and set that as the sole spec_helper file.
When you specify these files, do you use file: URLs or do you specify
them relative to the jasmine server root? And if the latter, can I do
something like "/__JASMINE_ROOT__/../../public/js/foo.js"? Or can I
specify an __APP_ROOT__ (better)?
Sorry if I sounded like a grinch yesterday! As penance I'm working on
some of those documentation improvements you said you wanted. Merry
Christmas!
---
Alex Chaffee - al...@cohuman.com - http://alexch.github.com
Stalk me: http://friendfeed.com/alexch | http://twitter.com/alexch |
http://alexch.tumblr.com
This should be in the defaults section of geminstaller.yml. Better
yet, switch to Bundler.
Merry Christmas!
-- Chad
I think instead it should be overridden per github gem, as:
install_options: --source=http://gems.github.com
That way the rest of the gems will continue to be found via normal means.
It looks like Rajan updated the selenium-rc gem already; I'll put the
above into my fork for ragaskar-jsdoc_helper.
> Better yet, switch to Bundler.
I can see providing a bundler manifest -- is that what you mean? Since
Jasmine is meant to be a library more than an application, it's not
clear to me what's the appropriate way to use bundler.
> Merry Christmas!
And to you!
- A
It is safest to include all sources for all gems in the default
install_options. "Normal means" means falling back on your local
sources, which will break on others' environments, as you found...
> I can see providing a bundler manifest -- is that what you mean? Since
> Jasmine is meant to be a library more than an application, it's not
> clear to me what's the appropriate way to use bundler.
Use it for all gem dependencies - whatever you are currently using
GemInstaller for.