Add record to track overridden limits
Before, we were relying on just changing the cards_count in account, but this could create problems where the system to calculate the next card number fails due to the unique constraint.
This commit is contained in:
@@ -127,8 +127,8 @@ module Fizzy
|
||||
end
|
||||
|
||||
config.to_prepare do
|
||||
::Account.include(Account::Billing)
|
||||
::Signup.prepend(Fizzy::Saas::Signup)
|
||||
::Account.include Account::Billing, Account::Limited
|
||||
::Signup.prepend Fizzy::Saas::Signup
|
||||
CardsController.include(Card::LimitedCreation)
|
||||
Cards::PublishesController.include(Card::LimitedPublishing)
|
||||
|
||||
|
||||
@@ -1,13 +1,6 @@
|
||||
require "rake/testtask"
|
||||
|
||||
namespace :test do
|
||||
# task :prepare_saas => :environment do
|
||||
# require "rails/test_help"
|
||||
#
|
||||
# $LOAD_PATH.unshift Fizzy::Saas::Engine.root.join("test").to_s
|
||||
# require Fizzy::Saas::Engine.root.join("test/test_helper")
|
||||
# end
|
||||
|
||||
desc "Run tests for fizzy-saas gem"
|
||||
Rake::TestTask.new(saas: :environment) do |t|
|
||||
t.libs << "test"
|
||||
|
||||
Reference in New Issue
Block a user