Skip to content

Sync main with short-io-app, add tests and CI - #1

Open
rajpootathar wants to merge 15 commits into
mainfrom
short-io-app
Open

Sync main with short-io-app, add tests and CI#1
rajpootathar wants to merge 15 commits into
mainfrom
short-io-app

Conversation

@rajpootathar

@rajpootathar rajpootathar commented Jun 30, 2025

Copy link
Copy Markdown
Collaborator

Brings main up to date with short-io-app, and adds tests and CI.

Sample app changes

Already in this branch, not yet on main:

  • Integrated encrypted links functionality
  • Implemented automatic tracking conversions
  • destination url returned from handleIntent function

Tests

Four tests replacing assertEquals(4, 2 + 2):

  • the screen launches and shows all three buttons
  • onCreate initializes the SDK
  • no result is shown before any button is pressed
  • pressing "Create Secure Short Link" renders the key and a copy button

They run on the JVM under Robolectric, so no emulator is needed.

Only the secure URL button is clicked. createSecure is local AES-GCM with no
network. The other two buttons call the live Short.io API, so a test must never
press them.

CI

One job: resolve the SDK from JitPack, assemble, run unit tests, compile the
instrumented tests. Resolution is a separate step so a JitPack outage reads as a
dependency failure rather than a compile error.

No lint: the sample ships android:host="{your_domain}" as a placeholder, which
lint reports as an error.

Notes

Copilot AI review requested due to automatic review settings June 30, 2025 06:52

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Pull Request Overview

This PR integrates encrypted links functionality and updates the README to document the new secure URL features. The changes include updates to intent handling using lifecycleScope, the introduction of a new Compose button for creating secure URLs, and an upgrade of the Short.io Android SDK dependency.

Reviewed Changes

Copilot reviewed 3 out of 3 changed files in this pull request and generated 1 comment.

File Description
app/src/main/java/com/github/shortioapp/MainActivity.kt Updates intent handling and adds a new secure URL creation Composable function.
app/build.gradle.kts Upgrades the Short.io Android SDK dependency version.
README.md Documents the new secure URL feature and provides sample usage.

Comment thread app/src/main/java/com/github/shortioapp/MainActivity.kt
@rajpootathar rajpootathar changed the title Integrated encrypted links functionality and updated the README.md file Integrated encrypted links functionality, tracking conversions, destination url Aug 8, 2025
@rajpootathar
rajpootathar marked this pull request as draft August 12, 2025 15:25
@rajpootathar
rajpootathar marked this pull request as ready for review August 15, 2025 11:19
Replaces the Android Studio placeholder with four tests covering launch,
SDK initialization, empty initial state, and secure URL generation.

Runs on the JVM under Robolectric rather than an emulator. Only the secure
URL button is clicked: createSecure is local AES-GCM, while the other two
buttons call the live Short.io API and must never run from a test.
Resolves the SDK from JitPack as its own step so an outage reads as a
dependency failure, then assembles, runs the unit tests, and compiles the
instrumented tests without an emulator.

Lint is not run: the sample ships android:host="{your_domain}" as a
fill-in-the-blank placeholder, which lint reports as an AppLinkUrlError.

Also ignores .idea and .kotlin, and untracks the .idea files already
committed.
@coderabbitai

coderabbitai Bot commented Aug 31, 2026

Copy link
Copy Markdown

Important

  • 🔍 Trigger review

This repository does not receive automatic reviews because it has fewer than 10 stars.

⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Team

Run ID: 72d564e4-ed08-4e90-8a5b-298c8d28e551


Comment @coderabbitai help to get the list of available commands.

@rajpootathar rajpootathar changed the title Integrated encrypted links functionality, tracking conversions, destination url Sync main with short-io-app, add tests and CI Aug 31, 2026
Checkout leaves a repo-scoped token in .git/config for the rest of the job; nothing here pushes, so it does not need one.
The main ruleset requires a status check called test; the job above reports as build, so nothing satisfied it and PRs stayed blocked.
The button displayed securedShortUrl on its own, which is only the "#<key>"
fragment, so the screen showed a bare AES key labelled as a URL and the
ciphertext went nowhere but logcat. It now shortens the ciphertext and
appends the key to the returned short URL.

createShortLink blocks, so the work moves off the Compose main dispatcher
onto a background thread.
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.

3 participants