summaryrefslogtreecommitdiffstats
path: root/spec/evas_spec.rb
diff options
context:
space:
mode:
authorJérémy Zurcher <jeremy@asynk.ch>2012-02-27 11:37:06 +0100
committerJérémy Zurcher <jeremy@asynk.ch>2012-02-27 11:37:06 +0100
commit7603f4c0902bf5845c7e7654c3745f5519347c8b (patch)
treebd381bf3a7f04d2ee7ddd92111c35a03472c7ecf /spec/evas_spec.rb
parent8c013976d73850718e75bbc93a03f3f016fc3ae8 (diff)
downloadffi-efl-7603f4c0902bf5845c7e7654c3745f5519347c8b.zip
ffi-efl-7603f4c0902bf5845c7e7654c3745f5519347c8b.tar.gz
use instance_eval instead of yield self.
- simplify and highlights initialization code - but shadows external scope variables
Diffstat (limited to 'spec/evas_spec.rb')
-rw-r--r--spec/evas_spec.rb5
1 files changed, 3 insertions, 2 deletions
diff --git a/spec/evas_spec.rb b/spec/evas_spec.rb
index f5f5859..e7dbdf9 100644
--- a/spec/evas_spec.rb
+++ b/spec/evas_spec.rb
@@ -73,8 +73,9 @@ describe "Efl::Evas #{Efl::Evas.version.full}" do
end
#
it "should be able to create and destroy evas" do
- e1 = Evas::REvas.new
- e1.address.should_not == 0
+ e1 = Evas::REvas.new do
+ address.should_not == 0
+ end
e2 = Evas::REvas.new e1.to_ptr
e1.address.should == e2.address
(e1==e2).should be_false