Skip to content

Commit

Permalink
update test
Browse files Browse the repository at this point in the history
  • Loading branch information
pan-xiong committed Sep 29, 2023
1 parent cc895b9 commit ea5de7c
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
5 changes: 2 additions & 3 deletions features/ranking_snapshots.feature
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,5 @@ Feature: Ranking Snapshots pages
When I visit the '/ranking_snapshots/long_selling_tools' page
Then I see '距离顶部下跌幅度的排行' text
Then I see '币种' text
Then I see 'ENJUSDT' text
Then I see '距离顶部下跌幅度' text
Then I see '90.0 %' text
Then I see 'BTCUSDT' text
Then I see '距离顶部下跌幅度' text
3 changes: 2 additions & 1 deletion features/step_definitions/ranking_snapshots_step.rb
Original file line number Diff line number Diff line change
Expand Up @@ -2,5 +2,6 @@
allow(SyncFuturesTickerService).to receive(:get_price_ratio).and_return([])
create(:ranking_snapshot, symbol: 'BTCUSDT', open_price: 100, last_price: 135, event_date: Date.parse('2023-01-05'))
create(:ranking_snapshot, symbol: 'ETHUSDT', open_price: 2, last_price: 3.5, event_date: Date.parse('2023-02-08'))
$redis.set('get_24hr_tickers', RankingSnapshot.get_rankings.to_json)
$redis.set('get_24hr_tickers', RankingSnapshot.get_daily_rankings.to_json)
$redis.set('get_top_24hr_tickers', RankingSnapshot.get_daily_rankings.to_json)
end

0 comments on commit ea5de7c

Please sign in to comment.