Real-Time Trading Scenario
Instructions: This is a test flow for a simulated real-time cryptocurrency trading application.
- Login: Start by clicking "Start Trading". You will be redirected to a login page. Use "trader" / "password123" to log in.
- Observe Market: On the trading page, observe the live price updates for various cryptocurrencies. The test should wait for a price change to confirm the data feed is active.
- Place a Buy Order: Select "Bitcoin (BTC)" from the dropdown, enter an amount (e.g., 0.5), and click the "Buy" button.
- Verify Trade: Assert that a confirmation message appears and that the transaction is listed in the "Trade History" panel.
- Check Portfolio: Navigate to the "Portfolio" page and verify that the purchased Bitcoin is correctly listed with the right amount.
- Place a Sell Order: Return to the trading page. Select "Bitcoin (BTC)", enter an amount to sell (e.g., 0.2), and click "Sell".
- Verify Sale: Assert that the sell order is confirmed and appears in the trade history.
- Verify Portfolio Update: Navigate back to the portfolio and assert that the Bitcoin balance has been updated correctly.