• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

decentraland / marketplace / 9999902307

18 Jul 2024 11:10PM UTC coverage: 66.468% (-0.2%) from 66.682%
9999902307

Pull #2268

github

meelrossi
fix isBid trade calculation
Pull Request #2268: feat: add accept trade flow

2635 of 5152 branches covered (51.15%)

Branch coverage included in aggregate %.

71 of 128 new or added lines in 11 files covered. (55.47%)

3 existing lines in 2 files now uncovered.

7714 of 10418 relevant lines covered (74.04%)

77.68 hits per line

Source File
Press 'n' to go to next uncovered line, 'b' for previous

70.59
/webapp/src/components/Bid/Bid.container.ts
1
import { connect } from 'react-redux'
1✔
2
import { isLoadingType } from 'decentraland-dapps/dist/modules/loading/selectors'
1✔
3
import { cancelBidRequest, archiveBid, unarchiveBid, acceptBidRequest, ACCEPT_BID_REQUEST } from '../../modules/bid/actions'
1✔
4
import { getLoading } from '../../modules/bid/selectors'
1✔
5
import { getContract } from '../../modules/contract/selectors'
1✔
6
import { getIsBidsOffChainEnabled } from '../../modules/features/selectors'
1✔
7
import { RootState } from '../../modules/reducer'
8
import { getArchivedBidIds } from '../../modules/ui/nft/bid/selectors'
1✔
9
import { Contract } from '../../modules/vendor/services'
10
import { getWallet } from '../../modules/wallet/selectors'
1✔
11
import Bid from './Bid'
1✔
12
import { MapStateProps, MapDispatchProps, MapDispatch } from './Bid.types'
13

14
const mapState = (state: RootState): MapStateProps => ({
1✔
15
  wallet: getWallet(state),
16
  archivedBidIds: getArchivedBidIds(state),
17
  isAcceptingBid: isLoadingType(getLoading(state), ACCEPT_BID_REQUEST),
18
  isBidsOffchainEnabled: getIsBidsOffChainEnabled(state),
NEW
19
  getContract: (query: Partial<Contract>) => getContract(state, query)
×
20
})
21

22
const mapDispatch = (dispatch: MapDispatch): MapDispatchProps => ({
1✔
23
  onCancel: bid => dispatch(cancelBidRequest(bid)),
×
24
  onArchive: bid => dispatch(archiveBid(bid)),
×
25
  onUnarchive: bid => dispatch(unarchiveBid(bid)),
×
26
  onAccept: bid => dispatch(acceptBidRequest(bid))
×
27
})
28

29
export default connect(mapState, mapDispatch)(Bid)
1✔
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2025 Coveralls, Inc