Sha256: 8ecba1267d8a0fc53bd67901dd7d096beba0445ae596025619c6ca2b3f28d97a
Contents?: true
Size: 743 Bytes
Versions: 21
Compression:
Stored size: 743 Bytes
Contents
require File.expand_path("helper", File.dirname(__FILE__)) class TransactionTest < ActiveSupport::TestCase context "Transactions" do should "have kasket disabled" do assert_equal true, Post.use_kasket? Post.transaction do assert_equal false, Post.use_kasket? end assert_equal true, Post.use_kasket? end end context "Nested transactions" do setup { Comment.has_kasket } should "disable kasket" do Post.transaction do assert_equal false, Comment.use_kasket? assert_equal false, Post.use_kasket? Comment.transaction do assert_equal false, Post.use_kasket? assert_equal false, Comment.use_kasket? end end end end end
Version data entries
21 entries across 21 versions & 1 rubygems