Displaying 20 results from an estimated 4000 matches similar to: ""should_not ==" vs "should !=""
2007 May 19
2
have_text matcher does not support should_not.
Hello Guys,
Doing conversion of some test for some controllers, still with integrated views.
Anyway, I have this:
it "should not see Join This Group button on profile page as member" do
get "show", :id => @group.id
response.should be_success
response.should_not have_text(/Join This Group/)
end
But running with spec (0.9.4), drop me the folling error:
2007 Jul 26
6
response.should_not redirect_to
Hey,
May be it is just too deep night over here and I''m missing something
though I got this failure on {{{response.should_not redirect_to}}}:
''QueuesController should allow authenticated user to access ''show''''
FAILED
Matcher does not support should_not.
See Spec::Matchers for more information
about matchers.
Also I''ve found this in
2011 Jul 25
6
What does using a lambda in rspec tests accomplish?
Here is the code in question:
describe UsersController do
render_views
…
…
describe "POST to ''create'' action" do
describe "failure" do
before(:each) do
@attr = { :name => '''', :email => '''', :password => '''',
:password_confirmation =>
2007 Apr 04
11
ANN: RSpec 0.9.0 beta-1 available for download.
We''d like to get some feedback on RSpec 0.9 before we start pushing
out releases via Rubyforge''s gem server and update the website. We
have therefore made the first beta of 0.9 available - both prepackaged
and tagged in subversion (see below).
RSpec 0.9 introduces a new API for expectations, which essentially
means that your underscores go away (there has been other discussions
2005 May 07
4
string syntactic sugar in R? - long post
Currently in R, constructing a string containing
values of variables is done using 'paste' and can be
an error-prone and traumatic experience. For example,
when constructing a db query we have to write,
paste("SELECT " value " FROM table where
date ='",cdate,"'")
we are getting null result from it, because without
(forgotten...)
2013 Oct 27
1
[LLVMdev] Add support for ldr pseudo instruction in ARM integrated assembler
So, it seems there are enough people on the plus side, I just wanted to
make sure we evaluate all sides before taking a decision to add syntactic
sugar to LLVM assembler.
My main concern is still the same as earlier this year: the integrated
assembler for ARM is still not complete, and the more extensions we add to
the back-end, the harder it'll be to get it into production quality.
That
2007 Aug 10
1
How to spec a model method
Still new to Specs...
How do I create a spec to test a model method? Specifically, here is my
spec:
#testing model
describe User do
it "should have many user roles" do
User.reflect_on_association(:user_roles).should_not be_nil
end
it "should have many roles though user roles" do
User.reflect_on_association(:roles).should_not be_nil
end
it "should know
2013 Oct 25
0
[LLVMdev] Add support for ldr pseudo instruction in ARM integrated assembler
On 25 October 2013 18:33, David Peixotto <dpeixott at codeaurora.org> wrote:
> Both armasm and gnu as support an ldr pseudo instruction for loading
> constants that lowers to either a mov, movn, or a pc-relative ldr from the
> constant pool. It would be great if the llvm integrated assembler could
> support this feature as well.
>
Hi David,
As much as I think that it's
2007 May 30
9
Specify attr_protected
This is kind of a two part question.
Question One: I want to be sure that an Order model is protecting
sensitive attributes from mass assignment.
The example looks like this:
describe Order do
it "should protect total attribute from mass assignment" do
@order = Order.new(:total => 0.05)
@order.total.should_not == 0.05
end
end
And the code to implement it:
class Order
2011 Apr 16
11
added new cool matcher into my framework WatirSplash - #in
Hello!
I''ve just added a new cool matcher #in into my framework WatirSplash
and thought that this could be integrated into RSpec directly actually
if there''s any interest.
WatirSplash uses Watir (or Watir-like) frameworks for testing web
pages via browser. If you''re not familiar with it then here is a short
example how you had to test ajax-heavy application before:
2013 Oct 25
5
[LLVMdev] Add support for ldr pseudo instruction in ARM integrated assembler
Both armasm and gnu as support an ldr pseudo instruction for loading
constants that lowers to either a mov, movn, or a pc-relative ldr from the
constant pool. It would be great if the llvm integrated assembler could
support this feature as well.
For example, using gnu as to compile this code:
.text
foo:
ldr r0, =0x1
ldr r0, =-0x1
ldr r0, =0x1000001
ldr r0, =bar
2007 Jan 29
3
Bug in should_not_be - What else to use?
Hi!
I just stumbled over a possible bug in 0.7.5.1:
`1.should_not_be == 1` does not fail.
I took a look into the code and figured out, that this is caused by
Not.be() using :no_arg instead of :___no_arg. The expected argument of
the method be() in Not is passed from should_not_be() with :___no_arg.
Not.be() is marked with "Gone for 0.9", so I assume that "should_not_be
=="
2017 Apr 26
2
LibFuzzer syntax sugar flag
Hi All,
Recently we have introduced a short syntactic sugar flag for compiling a file with libfuzzer:
one just needs to add “-fsanitize=fuzzer” to the command line, and the driver would specify
coverage flags and link with libfuzzer automatically.
I wanted to ask whether it would make more sense to rename the flag to “-ffuzzer”,
as it’s not a sanitizer, and it has a much heavier effect.
Thanks,
2013 Oct 25
3
[LLVMdev] Add support for ldr pseudo instruction in ARM integrated assembler
Hi Renato, Thanks for the thoughtful reply. Please find my thoughts below.
-- Qualcomm Innovation Center, Inc. is a member of Code Aurora Forum, hosted
by The Linux Foundation
From: Renato Golin [mailto:renato.golin at linaro.org]
Sent: Friday, October 25, 2013 1:11 PM
To: David Peixotto
Cc: LLVM Dev; Logan Chien; Gabor Ballabas; Rafael Espíndola; Richard Barton;
Amara Emerson
Subject:
2007 Nov 01
3
autotest debugger?
Hi,
I keep facing problems with autotest, and I don''t know what''s happening
in the background, is there anyway to know what''s happening while
testing?
Example:
@user = User.new
@user.email = "testcom"
@user.errors.on(:email).should_not be_empty
...throws error failure
- You have a nil object when you didn''t expect it!
- You might have expected an
2013 Oct 27
0
[LLVMdev] Add support for ldr pseudo instruction in ARM integrated assembler
On Oct 25, 2013, at 5:22 PM, Sean Silva <chisophugis at gmail.com> wrote:
> I’m not sure macros are a good analogy, but there are other pseudo-instructions that we’re not always able to reconstruct in disassembled code back to how the user wrote them. Or if we do, it’s purely via heuristic methods. I don’t see this as a big issue.
I agree. These pseudo instructions seem like pure
2007 Sep 20
4
alias :calling :lambda
Sprinkling my examples with ''lambda'' has always seemed like a bit of a
wart to me. I''ve gotten into the habit of adding ''alias :calling
:lambda'' to my spec suites. My examples then look like:
calling { Foo }.should raise_error
calling { Bar }.should_not raise_error
Is there a reason that RSpec core has chosen not to make exception
expectations more
2008 Jun 12
2
Use of ''should'' in another thread
Hi,
I''ve tried to find anything about using ''should'' within a Thread, but
it is a little hard do look up there, so I hope you forgive-me if I am
asking an "old question".
I guess this spec should fail:
describe Thread do
it "must be fine" do
Thread.new { true.should_not be_true } # Why don''t fail?!
end
end
It seems that some
2010 Aug 05
4
A %nin% operator?
Sometimes I write code like this:
> qf.a <- subset(qf, pubid %in% c(104, 106, 107, 108))
> qf.b <- subset(qf, !pubid %in% c(104, 106, 107, 108))
and I get a little worried that maybe I've remembered the precedence rules
wrong, so I change it to
> qf.a <- subset(qf, pubid %in% c(104, 106, 107, 108))
> qf.b <- subset(qf, !(pubid %in% c(104, 106, 107, 108)))
and pretty
2009 Feb 28
7
be_valid (validates_format_of ..., :on => :create)
Greetings,
How to write Example which will check if model''s variable''s
format is valid using :on => :create, like this:
class User < ActiveRecord::Base
...
validates_format_of :email, :with => /.../, :on => :create
...
Using following code is not right:
it "should ..." do
@user = users(:example_user)
@user.email =