Skip to content

Commit

Permalink
Run only failing test
Browse files Browse the repository at this point in the history
  • Loading branch information
reshmabidikar committed Sep 6, 2024
1 parent 5562a32 commit b8049c8
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 1 deletion.
2 changes: 1 addition & 1 deletion .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -144,7 +144,7 @@ jobs:
DB_PORT: ${{ matrix.database-port }}
run: |
# Some flakiness unfortunately
./bin/retry bundle exec rake test:core TESTOPTS="--stop-on-failure"
./bin/retry bundle exec rake test:core:ent_cancellation TESTOPTS="--stop-on-failure"
- name: Run plugins tests
env:
DB_ADAPTER: ${{ matrix.database-adapter }}
Expand Down
6 changes: 6 additions & 0 deletions Rakefile
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,12 @@ namespace :test do
t.verbose = true
end

Rake::TestTask.new('core:ent_cancellation') do |t|
t.libs << BASE_DIR
t.test_files = FileList["#{BASE_DIR}/core/test_entitlement_cancellation.rb"]
t.verbose = true
end

Rake::TestTask.new('core:invoice') do |t|
t.libs << BASE_DIR
t.test_files = FileList["#{BASE_DIR}/core/test_invoice_*.rb"]
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ module EntitlementChecker
include CheckerBase

def check_subscription(s, product_name, product_category, billing_period, price_list, start_date, cancelled_date, billing_start_date, billing_end_date, account_time_zone = nil)
puts "Debug actual end date: #{s.billing_end_date}, expected end date: #{billing_end_date}"
check_entitlement(s, product_name, product_category, billing_period, price_list, start_date, cancelled_date, account_time_zone)
assert_equal_dates(billing_start_date, s.billing_start_date, account_time_zone)
assert_equal_dates(billing_end_date, s.billing_end_date, account_time_zone)
Expand Down

0 comments on commit b8049c8

Please sign in to comment.