{"owner":"android","repo":"nowinandroid","hasSkills":true,"hasMcp":false,"mcpConfig":null,"found":["AGENTS.md"],"files":{"AGENTS.md":"# Now in Android Project\n\nNow in Android is a native Android mobile application written in Kotlin. It provides regular news\nabout Android development. Users can choose to follow topics, be notified when new content is\navailable, and bookmark items.\n\n## Architecture\n\nThis project is a modern Android application that follows the official architecture guidance from Google. It is a reactive, single-activity app that uses the following:\n\n-   **UI:** Built entirely with Jetpack Compose, including Material 3 components and adaptive layouts for different screen sizes.\n-   **State Management:** Unidirectional Data Flow (UDF) is implemented using Kotlin Coroutines and `Flow`s. `ViewModel`s act as state holders, exposing UI state as streams of data.\n-   **Dependency Injection:** Hilt is used for dependency injection throughout the app, simplifying the management of dependencies and improving testability.\n-   **Navigation:** Navigation is handled by Jetpack Navigation 2 for Compose, allowing for a declarative and type-safe way to navigate between screens.\n-   **Data:** The data layer is implemented using the repository pattern.\n    -   **Local Data:** Room and DataStore are used for local data persistence.\n    -   **Remote Data:** Retrofit and OkHttp are used for fetching data from the network.\n-   **Background Processing:** WorkManager is used for deferrable background tasks.\n\n## Modules\n\nThe main Android app lives in the `app/` folder. Feature modules live in `feature/` and core and shared modules in `core/`.\n\n## Commands to Build & Test\n\nThe app and Android libraries have two product flavors: `demo` and `prod`, and two build types: `debug` and `release`.\n\n- Build: `./gradlew assemble{Variant}`. Typically `assembleDemoDebug`.\n- Fix linting/formatting: `./gradlew spotlessApply`\n- Run local tests: `./gradlew {variant}Test`\n- Run single test: `./gradlew {variant}Test --tests \"com.example.myapp.MyTestClass\"`\n- Run local screenshot tests: `./gradlew verifyRoborazziDemoDebug`\n\n### Instrumented tests\n\n- Gradle-managed devices to run on device tests: `./gradlew pixel6api31aospDebugAndroidTest`. Also `pixel4api30aospatdDebugAndroidTest` and `pixelcapi30aospatdDebugAndroidTest`.\n\n### Creating tests\n\n#### Instrumented tests\n\n- Tests for UI features should only use `ComposeTestRule` with a `ComponentActivity`.\n- Bigger tests live in the `:app` module and they can start activities like `MainActivity`.\n\n#### Local tests\n\n- [kotlinx.coroutines](https://github.com/Kotlin/kotlinx.coroutines) for most assertions\n- [cashapp/turbine](https://github.com/cashapp/turbine) for complex coroutine tests\n- [google/truth](https://github.com/google/truth) for assertions\n\n## Continuous integration\n\n- The workflows are defined in `.github/workflows/*.yaml` and they contain various checks.\n- Screenshot tests are generated by CI, so they shouldn't be checked into the repo from a workstation.\n\n## Version control and code location\n\n- The project uses git and is hosted in https://github.com/android/nowinandroid.\n"}}