test/example-apps.rb in spqr-0.2.3 vs test/example-apps.rb in spqr-0.2.4
- old
+ new
@@ -196,5 +196,40 @@
end
qmf_package_name :example
qmf_class_name :Failbot
end
+
+class QmfListArg
+ include ::SPQR::Manageable
+
+
+ def qmf_oid
+ 1234
+ end
+
+ def spqr_object_id
+ 1234
+ end
+
+ def QmfListArg.find_by_id(oid)
+ @objs ||= [QmfListArg.new]
+ @objs[0]
+ end
+
+ def QmfListArg.find_all
+ @objs ||= [QmfListArg.new]
+ @objs
+ end
+
+ def double(ls)
+ ls.map {|x| 2 * x}
+ end
+
+ expose :double do |args|
+ args.declare :input, :list, :in
+ args.declare :ls, :list, :out
+ end
+
+ qmf_class_name :QmfListArg
+ qmf_package_name :example
+end