mirror of
https://github.com/rubyjs/therubyracer
synced 2023-03-27 23:21:42 -04:00
![Charles Lowell](/assets/img/avatar_default.png)
Even though they had been moved into the `ClassAction` module, that module still had the potential for conflict. Instead, we'll just put evenything in the Conversion namespace. That way we need not worry.
21 lines
463 B
Ruby
21 lines
463 B
Ruby
require 'spec_helper'
|
|
require 'bigdecimal'
|
|
describe V8::Conversion do
|
|
it "can embed BigDecimal values" do
|
|
cxt = V8::Context.new
|
|
cxt['big'] = BigDecimal.new('1.1')
|
|
cxt['big'].should eql BigDecimal.new('1.1')
|
|
end
|
|
|
|
it "doesn't try to use V8::Conversion::Class::* as root objects" do
|
|
klass = Class.new do
|
|
class << self
|
|
def test
|
|
Set.new
|
|
end
|
|
end
|
|
end
|
|
|
|
klass.test.should be_instance_of(::Set)
|
|
end
|
|
end
|