Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: Send Earn #1085

Open
wants to merge 64 commits into
base: dev
Choose a base branch
from
Open

feat: Send Earn #1085

wants to merge 64 commits into from

Conversation

0xBigBoss
Copy link
Contributor

  • fix: StartEarning -> Deposit
  • feat: add oliveDrab color

@0xBigBoss 0xBigBoss changed the title bb/send earn feat: Send Earn Feb 16, 2025
Copy link

github-actions bot commented Mar 6, 2025

Playwright Report

Summary

Expected Skipped Unexpected Flaky Duration
80 6 2 4 234.23s

Suites

account-rewards.onboarded.spec.ts

can visit rewards page

  • chromium: ✅
  • firefox: ✅

account-sendtag-checkout.onboarded.spec.ts

can visit checkout page

  • chromium: ✅
  • firefox: ✅

can add a pending tag

  • chromium: ✅
  • firefox: ✅

cannot add an invalid tag name

  • chromium: ✅
  • firefox: ✅

can confirm a tag

  • chromium: 🚨
  • firefox: ✅

can refer a tag

  • chromium: ✅
  • firefox: ✅

can refer multiple tags in separate transactions

  • chromium: ✅
  • firefox: ✅

cannot confirm a tag without paying

  • chromium: ✅
  • firefox: ✅

cannot add more than 5 tags

  • chromium: ✅
  • firefox: ✅

account-settings-backup.onboarded.spec.ts

can backup account

  • chromium: ✅
  • firefox: ✅

can remove a signer

  • chromium: ✅
  • firefox: ✅

account.logged-in.spec.ts

can visit account page

  • chromium: ✅
  • firefox: ✅

can update profile

  • chromium: ✅
  • firefox: ✅

activity.onboarded.spec.ts

can visit activity page and see correct activity feed

  • chromium: ✅
  • firefox: ✅

can search on activity page

  • chromium: ✅
  • firefox: ✅

earn.onboarded.spec.ts

can deposit USDC into SendEarn

  • chromium: ❌
    • ContractFunctionExecutionError: The contract function "balanceOf" returned no data ("0x").

This could be due to any of the following:

  • The contract does not have the function "balanceOf",
  • The parameters passed to the contract function may be invalid, or
  • The address is not a contract.

Contract Call:
address: 0x02E27B9dEae5d76e3d7696447c771b03C0Cc3F42
function: balanceOf(address account)
args: (0xEA9BA34211C61FeF23D26BA841673934c2dbAdA8)

Docs: https://viem.sh/docs/contract/readContract
Version: [email protected]

�[0m �[90m 43 |�[39m
�[90m 44 |�[39m �[90m// first get shares�[39m
�[31m�[1m>�[22m�[39m�[90m 45 |�[39m �[36mconst�[39m shares �[33m=�[39m �[36mawait�[39m readSendEarnBalanceOf(config�[33m,�[39m {
�[90m |�[39m �[31m�[1m^�[22m�[39m
�[90m 46 |�[39m args�[33m:�[39m [sendAccount�[33m.�[39maddress]�[33m,�[39m
�[90m 47 |�[39m chainId�[33m:�[39m testBaseClient�[33m.�[39mchain�[33m.�[39mid�[33m,�[39m
�[90m 48 |�[39m })�[0m

at getContractError (/home/runner/_work/sendapp/sendapp/node_modules/viem/utils/errors/getContractError.ts:78:10)
at readContract (/home/runner/_work/sendapp/sendapp/node_modules/viem/actions/public/readContract.ts:136:11)
at /home/runner/_work/sendapp/sendapp/packages/playwright/tests/earn.onboarded.spec.ts:45:18
  • firefox: ❌
    • Error: �[31mTimed out 5000ms waiting for �[39m�[2mexpect(�[22m�[31mlocator�[39m�[2m).�[22mtoBeVisible�[2m()�[22m

Locator: getByText('Deposited successfully', { exact: true })
Expected: visible
Received: <element(s) not found>
Call log:
�[2m- expect.toBeVisible with timeout 5000ms�[22m
�[2m - waiting for getByText('Deposited successfully', { exact: true })�[22m

Call Log:

  • Timeout 15000ms exceeded while waiting on the predicate

    at fixtures/deposit/index.ts:74

�[0m �[90m 72 |�[39m �[36mawait�[39m expect(�[36mthis�[39m�[33m.�[39mpage�[33m.�[39mgetByText(�[32m'Deposited successfully'�[39m�[33m,�[39m { exact�[33m:�[39m �[36mtrue�[39m }))�[33m.�[39mtoBeVisible()
�[90m 73 |�[39m �[36mawait�[39m �[36mthis�[39m�[33m.�[39mpage�[33m.�[39mwaitForURL(�[32m'/earn'�[39m)
�[31m�[1m>�[22m�[39m�[90m 74 |�[39m })�[33m.�[39mtoPass({
�[90m |�[39m �[31m�[1m^�[22m�[39m
�[90m 75 |�[39m timeout�[33m:�[39m �[35m15�[39m_000�[33m,�[39m
�[90m 76 |�[39m })
�[90m 77 |�[39m }�[0m

at EarnDepositPage.submit (/home/runner/_work/sendapp/sendapp/packages/playwright/tests/fixtures/deposit/index.ts:74:8)
at /home/runner/_work/sendapp/sendapp/packages/playwright/tests/earn.onboarded.spec.ts:42:14

home.onboarded.spec.ts

can visit token detail page

  • chromium: ✅
  • firefox: ✅

leaderboard.logged-in.spec.ts

can visit leaderboard page

  • chromium: ✅
  • firefox: ✅

onboarding.logged-in.spec.ts

can visit onboarding page

  • chromium: ✅
  • firefox: ✅

profile.anon.spec.ts

anon user can visit public profile

  • chromium: ✅
  • firefox: ✅

anon user cannot visit private profile

  • chromium: ✅
  • firefox: ✅

profile.logged-in.spec.ts

logged in user needs onboarding before visiting profile

  • chromium: ✅
  • firefox: ✅

profile.onboarded.spec.ts

can visit other user profile and send by tag

  • chromium: ✅
  • firefox: ✅

can visit my own profile

  • chromium: ✅
  • firefox: ✅

can visit private profile

  • chromium: ✅
  • firefox: ✅

can view activities between another profile

  • chromium: ✅
  • firefox: ✅

send-token-upgrade.onboarded.spec.ts

can upgrade their Send Token V0 to Send Token V1

  • chromium: ✅
  • firefox: ✅

send.onboarded.spec.ts

can send USDC starting from profile page

  • chromium: ✅
  • firefox: ✅

can send USDC using tag starting from home page

  • chromium: ✅
  • firefox: ✅

can send USDC using sendid starting from home page

  • chromium: ✅
  • firefox: ✅

can send USDC using address starting from home page

  • chromium: ✅
  • firefox: ✅

can send ETH starting from profile page

  • chromium: 🚨
  • firefox: ✅

can send ETH using tag starting from home page

  • chromium: 🚨
  • firefox: ✅

can send ETH using sendid starting from home page

  • chromium: ✅
  • firefox: 🚨

can send ETH using address starting from home page

  • chromium: ✅
  • firefox: ✅

can send SEND starting from profile page

  • chromium: ✅
  • firefox: ✅

can send SEND using tag starting from home page

  • chromium: ✅
  • firefox: ✅

can send SEND using sendid starting from home page

  • chromium: ✅
  • firefox: ✅

can send SEND using address starting from home page

  • chromium: ✅
  • firefox: ✅

sign-in.anon.spec.ts

redirect on sign-in

  • chromium: ✅
  • firefox: ✅

redirect to send confirm page on sign-in

  • chromium: ✅
  • firefox: ✅

sign-up.anon.spec.ts

can sign up

  • chromium: ✅
  • firefox: ✅

country code is selected based on geoip

  • chromium: ✅
  • firefox: ✅

skip otp for existing user trying to sign up using already used phone number

  • chromium: ⏭
  • firefox: ⏭

user can sign in with passkey from backing up page

  • chromium: ⏭
  • firefox: ⏭

user can sign in as back up using otp from backing up page

  • chromium: ⏭
  • firefox: ⏭

musidlo and others added 28 commits March 6, 2025 11:52
handle terms acceptance and improve error handling logic
ensure defaultUserOp is treated as const and log userOpQueryOptions parameters for better debugging
enhanced error handling in DepositForm
use zeroAddress for default sender in useSendEarnDepositUserOp function
return null for invalid inputs in sanitizeAmount to prevent errors in WithdrawForm and SendAmountForm
validate deposit amount and clear errors accordingly in the form
…dling in DepositForm for better validation logic
@0xBigBoss 0xBigBoss changed the base branch from earn-ui to dev March 6, 2025 20:05
0xBigBoss added 19 commits March 7, 2025 12:56
refactor sendEarnDepositVault logic for improved referrer support
…handling cases and extend functionality for ZodError
add comprehensive unit tests for formatting various coin amounts accurately
types to enhance transaction tracking for deposits and withdrawals
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants