mirror of
				https://github.com/rubyjs/therubyracer
				synced 2023-03-27 23:21:42 -04:00 
			
		
		
		
	add seeds for passing javascript objects back to ruby
This commit is contained in:
		
							parent
							
								
									68c968e109
								
							
						
					
					
						commit
						c0d8d85b95
					
				
					 3 changed files with 19 additions and 0 deletions
				
			
		| 
						 | 
				
			
			@ -41,6 +41,14 @@ describe "The Ruby Racer" do
 | 
			
		|||
      eval("true").should be(true)
 | 
			
		||||
      eval("false").should be(false)
 | 
			
		||||
    end
 | 
			
		||||
    
 | 
			
		||||
    it "can pass objects back to ruby" do
 | 
			
		||||
      eval("({foo: 'bar', baz: 'bang'})").tap do |object|
 | 
			
		||||
        object.should_not be_nil
 | 
			
		||||
        object['foo'].should == 'bar'
 | 
			
		||||
        object['baz'].should == 'bang'
 | 
			
		||||
      end
 | 
			
		||||
    end
 | 
			
		||||
        
 | 
			
		||||
  end
 | 
			
		||||
  
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue