Skip to content

Conversation

@liviu-timar
Copy link
Contributor

@liviu-timar liviu-timar commented Mar 28, 2025

🎯 Goal

  • Read call ID from launch intent extra. Useful for testing scenarios.

🛠 Implementation details

  • Reading the call ID from the extra with key io.getstream.video.android.demoapp.CALL_ID:
internal const val EXTRA_CALL_ID = "io.getstream.video.android.demoapp.CALL_ID"

val intent = Intent(composeTestRule.activity, MainActivity::class.java).apply {
    putExtra(EXTRA_CALL_ID, testCallId)
}

Future improvements:

  • Sanitize the call ID
  • Keep the call ID in the ViewModel
  • Preserve the launch intent call ID when ending a call

🧪 Testing

  • Use the above intent to launch the app
  • Use this launch flag in terminal/Android Studio: -e io.getstream.video.android.demoapp.CALL_ID test-call-1234

🎉 GIF

@liviu-timar liviu-timar requested a review from a team as a code owner March 28, 2025 14:53
@liviu-timar liviu-timar changed the title Read call ID from launch intent extra [AND-429] Read call ID from launch intent extra Mar 28, 2025
@github-actions
Copy link
Contributor

github-actions bot commented Mar 28, 2025

SDK Size Comparison 📏

SDK Before After Difference Status
stream-video-android-core 11.21 MB 11.21 MB 0.00 MB 🟢
stream-video-android-ui-xml 5.66 MB 5.66 MB 0.00 MB 🟢
stream-video-android-ui-compose 5.83 MB 5.83 MB 0.00 MB 🟢

Copy link
Contributor

@testableapple testableapple left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM! 👍

Just a quick question, do we need these dependencies in DemoApp and these sample tests? I have a local branch with the testing infra setup that will conflict with these changes.

@testableapple
Copy link
Contributor

@liviu-timar, could we also add an option to pass the user id/name via intent?

@liviu-timar
Copy link
Contributor Author

liviu-timar commented Apr 4, 2025

LGTM! 👍

Just a quick question, do we need these dependencies in DemoApp and these sample tests? I have a local branch with the testing infra setup that will conflict with these changes.

@testableapple You don't need the changes from build.gradle, the androidTest folder and library.versions.toml. Try it out and let me know how it works.

Maybe it's best to move them to a different PR. 🤔


could we also add an option to pass the user id/name via intent?

I'll check and create a different PR if feasible.

@liviu-timar liviu-timar requested a review from Copilot April 8, 2025 06:42
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot reviewed 9 out of 10 changed files in this pull request and generated no comments.

Files not reviewed (1)
  • demo-app/build.gradle.kts: Language not supported

@testableapple
Copy link
Contributor

Hey @liviu-timar, just tested the new callId argument, works like a charm!

QQ, could we implement only the changes under demo-app/src/main? I believe the other changes are excessive and will conflict with my work on #1349. WDYT?

Copy link
Contributor

@testableapple testableapple left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM 🙌

@liviu-timar
Copy link
Contributor Author

Hey @liviu-timar, just tested the new callId argument, works like a charm!

QQ, could we implement only the changes under demo-app/src/main? I believe the other changes are excessive and will conflict with my work on #1349. WDYT?

Done, can you do a quick test again?

@liviu-timar liviu-timar enabled auto-merge (squash) April 8, 2025 15:16
@liviu-timar liviu-timar merged commit ac2f73c into develop Apr 8, 2025
6 checks passed
@liviu-timar liviu-timar deleted the pass-call-id branch April 8, 2025 15:21
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.

4 participants