similar to: Testing cookies - integration tests

Displaying 20 results from an estimated 7000 matches similar to: "Testing cookies - integration tests"

2006 May 25
0
post to a webservice in an integration test?
Hey railers, Just wondering if anyone out there knows how to generate a SOAP post using the session object in an integration test. I couldn''t find documentation on how to do so, but perhaps I''m overlooking something. I would like to call a webservice on my server in the following block: def login open_session do |sess| ... sess.post
2007 Mar 03
5
url_for and arrays parameters (diffs between rails 1.1.6 and 1.2.2)
Hello, I posted this to the main rails list (http://www.ruby-forum.com/topic/99845), but haven''t received any replies yet, so maybe this question is better suited here. Sorry if this has been brought up before, I couldn''t find any previous discussion on this. To summarize the post... When using the latest Rails (1.2.2) I''m passing an array to url_for like so...
2006 Apr 03
0
Cookies and functional tests
Hi there Is there any way that my functional tests can check to see if the controller has set a cookie? I''ve got this in a controller action; def login cookies[:foo] = ''bar'' end Using a web browser, I can see that the cookie is being set when the action is invoked. But, a functional test like this; def test_cookie assert_equal nil,
2006 Jan 10
0
problem with cookies in tests (TDD)
The problem I''m having is that I can''t seem to destroy the cookies and assert that they were indeed destroyed inside the test. The code to do this does work - the cookies are created, and are destroyed when this is done in a browser, but I can''t seem to make the test pass. account_signup_test.rb def test_should_pass_if_logout_destroys_cookie_data post :login,
2007 Mar 19
0
cookies
How do I set cookies in a spec so I can see them in my controller, please? Conversely, why doesn''t this work... require File.dirname(__FILE__) + ''/../spec_helper'' class TestApplicationController < ApplicationController def index @seen = cookies[''auth_token''] || ''NOT seen!'' puts cookies.inspect #
2007 Oct 04
1
Cookies in RSpec
So how do you work with cookies properly in rspec now? I noticed in the docs that it mentions session, assigns, and flash, but nothing of cookie. I''m using edge rails so I''m concerned about changes to the cookie mechanisms. I need to assign values into the cookie (a remember token for restful authentication) so that I can have it log in by cookie. here is my spec
2006 Feb 19
0
Re: can store array or hash in cookies?
Not a bug. A cookie is just a string. You can turn anything into a string and store it in a cookie. Something very simple like the following might work for you: array_for_cookie = [1,4,5,7] cookies[:foo] = array_for_cookie .to_s array_from_cookie = cookies[:foo][1..-2].split('','') (And if you are just storing a single integer in a cookie be sure to turn it into a
2003 Oct 12
0
idea (and patch): connection cookies
I have an idea for a protocol extension to limit the exposure of the complex crypto code in ssh servers. It's like tcp-wrappers, but based on a secret token rather than IP address. Patch against openssh-3.7.1p2: http://nick.cleaton.net/openssh-cc-0.03.patch Details ======= The "Connection Cookies" mechanism is an unofficial ssh protocol extension designed to prevent attackers
1999 Nov 22
0
OpenSSH 1.2pre14 fails on pam_open_session() ...
Anyone out there know more about PAM under Solaris 7/x86 then I do, that can maybe tackle this, and/or suggestion a route to take to fix? After doing some debugging, it looks like the problem is a seg fault at: sshd.c:void pam_cleanup_proc(void *context) =========================================== debug("PAM_retval(open_session) about to run"); pam_retval =
2010 Nov 14
1
RCurl and cookies in POST requests
Hello. I know that it's usually possible to write cookies to a cookie file by removing the curl handle and doing a gc() call. I can do this with getURL(), but I just can't obtain the same results with postForm(). If I use: curlHandle <- getCurlHandle(cookiefile=FILE, cookiejar=FILE) and then do: getURL(http://example.com/script.cgi, curl=curlHandle) rm(curlHandle) gc() it's
2001 Nov 15
2
X11 cookies and forwarding
I'm guess I wasn't following the whole cookies discussion completely (putting cookies in /tmp to avoid putting them on NFS, etc.), but I noticed today that with 2.9.9p2, if I use "ssh -X" to start a shell on the server, in that shell XAUTHORITY is set to /tmp/ssh-XXXXXXXX/cookies and there are cookies placed there there. These are the "fake" cookies for the
2007 Jan 29
2
rspec and cookies
Hello can anyone tell me how to test cookies using rspec? specifically, I''d like to be able to set a cookie before a get/post request and also to test the cookies which have been set by a get/post request I know I can use cookies[:name] = ''value'' to set a cookie but how would I set expiry information on such a cookie? when i try to pass a hash {:value =>
2006 Nov 24
0
Maybe a bug in Cookie:cookies
Hi man, Thank you very much for your good work. I think there may be a bug in Mechanize 0.6.3. Cookie:cookies (cookie.rb:L83 ) @jar[domain].each_key do |name| => if url.path =~ /^#{@jar[domain][name].path}/ if @jar[domain][name].expires.nil? cookies << @jar[domain][name] elsif Time.now <
2018 May 15
0
[PATCH 1/2] Convert target drivers to use sbitmap
From: Matthew Wilcox <mawilcox at microsoft.com> The sbitmap and the percpu_ida perform essentially the same task, allocating tags for commands. Since the sbitmap is more used than the percpu_ida, convert the percpu_ida users to the sbitmap API. Signed-off-by: Matthew Wilcox <mawilcox at microsoft.com> --- drivers/scsi/qla2xxx/qla_target.c | 16 ++++++-----
2007 Aug 17
1
Testing webservices in Integration Tests with Jamis Buck's recipe?
Hello, I''m using Jamis Buck''s recipe to do integration tests on an application, but I got a nil.recycle! error while doing a webservice call. This is the situation. def test_uploading_data invoke :upload, data invoke :upload, even_more_data real_user_session = new_session_as @real_user real_user_session.press_magic_button_to_enable_more_uploads invoke :upload,
2000 Dec 22
1
XAUTHORITY=/tmp/ssh-*/cookies makes forwarding through firewall difficult...
Hi. I see this XAUTHORITY=/tmp/ssh-*/cookies issue has been discussed repeatedly, but I haven't seen a solution to the following problem. Remote user logs into firewall. On firewall, DISPLAY var set to secure channel, XAUTHORITY set to /tmp/ssh-*/cookies. X11 forwarding from firewall works fine. User logs into machine behind firewall, and sets DISPLAY var to firewall:X11DisplayOffset.0.
2006 Apr 05
0
cookies not deleting?????
I was running into a problem where i was setting two different cookies for " www.myapp.com" and "myapp.com". To fix this, when i set the cookie i specified the domain to be ".myapp.com". However now when i try to delete the cookie cookies.delete :myapp_cookie, it wont delete. Why is that? Here is my code: when logging in - ... cookies[:myapp_cookie] = {:value
2006 Jan 11
0
Cookies, models and nil objects
Still new in my ROR walk, been busily coding on a game application as a fruitful exercise in becoming proficient in Ruby/ROR. However, I seem to have hit a speed bump and am befuddled over some exhibited behavior in ROR. 1. **Cookies** - on page 312 of the AWDwR book by DT and DHH, it states that if you create a cookie by assigning a value to cookies[name], you get a "default set of
2006 Dec 01
2
Mongrel 0.3.18, rails 1.1.6 and cookies
I''ve run into an issue with my rails application being unable to properly set cookies on Mongrel 0.3.18. If I run the simplified code below in Mongrel 3.14.4, both cookies are properly sent to and saved by the browser. With the same code in 0.3.18, only the auth_token cookie is created (if I switch them, only the userid as it will only properly create the first cookie in the list.)
2001 Nov 15
1
X11 cookies and forwarding (fwd)
On Thu, 15 Nov 2001, Dan Astoorian wrote: > Date: Thu, 15 Nov 2001 16:09:20 -0500 > From: Dan Astoorian <djast at cs.toronto.edu> > To: Ed Phillips <ed at UDel.Edu> > Subject: Re: X11 cookies and forwarding > > On Thu, 15 Nov 2001 15:46:22 EST, Ed Phillips writes: > > I'm guess I wasn't following the whole cookies discussion completely > >