Conversation
Adding Android Project
Added basic layout for Groups page.
Groups page
Implement data from json later to pass tests
-Updated Theme folder
…ain_Page2 � Conflicts: � app/src/main/java/com/example/workoutapp/MainActivity.kt
| androidTestImplementation "androidx.compose.ui:ui-test-junit4:$compose_ui_version" | ||
| debugImplementation "androidx.compose.ui:ui-tooling:$compose_ui_version" | ||
| debugImplementation "androidx.compose.ui:ui-test-manifest:$compose_ui_version" | ||
| implementation 'com.squareup.retrofit2:retrofit:2.9.0' |
There was a problem hiding this comment.
had to change version for retrofit2 to work
| } | ||
|
|
||
| } | ||
| @Preview(name="Light Mode", showBackground=true) |
There was a problem hiding this comment.
added preview so emulator would not need to be reran
| } | ||
| } | ||
|
|
||
| @Preview(showBackground = true) |
There was a problem hiding this comment.
this line was redlining and didn't work to show preview
|
|
||
|
|
||
| @Preview(name="Light Mode", showBackground=true) | ||
| @Preview(uiMode= Configuration.UI_MODE_NIGHT_YES, showBackground = true, name="Dark Mode") |
There was a problem hiding this comment.
refactored to make preview work
| @@ -0,0 +1,21 @@ | |||
| package com.example.workoutapp | |||
There was a problem hiding this comment.
added missing RetrofitClientInstance file. Implementing this and DAO and DTO packaged should help make unit tests run.
|
|
||
| object RetrofitClientInstance { | ||
| private var retrofit: Retrofit? = null | ||
| private val BASE_URL = "" |
There was a problem hiding this comment.
add your own base URL from your JSON link (boilerplate code)
|
|
||
| } | ||
| } | ||
| @Preview(name="Light Mode", showBackground=true) |
There was a problem hiding this comment.
added another preview
| @@ -0,0 +1,6 @@ | |||
| package com.example.workoutapp.service | |||
There was a problem hiding this comment.
need to implement WorkoutService with fetchWorkouts function to parse JSON data
There was a problem hiding this comment.
This appears to be an incomplete feature, as there's not a BASE_URL. Recommendation: if not used, remove it, or keep it in a separate development branch until it is complete.
Keep the codebase as small as possible to do the job you want to do. Unused code is clutter, and bad documentation, which increases technical debt.
Only complete features, which meet the team's Definition of Done, should be merged to Main/Master.
|
|
||
| @Test | ||
| fun `Given a dto when name is Barbell Curl, and level is beginner`() { | ||
| var workout = Workout("Barbell Curl", "pull", "beginner", "isolation", "barbell", "biceps", "forearms", |
There was a problem hiding this comment.
need to implement Workout class
| @@ -0,0 +1,167 @@ | |||
| package com.example.workoutapp | |||
There was a problem hiding this comment.
these unit tests failed for me because of lack to implement necessary classes for it
| import retrofit2.http.GET | ||
|
|
||
| interface IWorkoutDAO { | ||
| @GET("") |
There was a problem hiding this comment.
put your own json link here
There was a problem hiding this comment.
This appears to be an incomplete feature, as there's not a BASE_URL. Recommendation: if not used, remove it, or keep it in a separate development branch until it is complete.
Keep the codebase as small as possible to do the job you want to do. Unused code is clutter, and bad documentation, which increases technical debt.
Only complete features, which meet the team's Definition of Done, should be merged to Main/Master.
| @@ -0,0 +1,5 @@ | |||
| package com.example.workoutapp.dto | |||
|
|
|||
| class Workout { | |||
There was a problem hiding this comment.
I couldn't find your json link anywhere to come up with the workout class myself
|
Some good suggestions here, though I wouldn't recommend merging this branch at this time.
|
This is a workout logging app designed to be able to track your own workouts and find workouts from the JSON data. The user can also make groups for workouts as well.
Yes, submitted on time.
Yes, the program is well documented. There are comments explaining pretty much what each function and class does.
The unit tests did not compile for me. I'm not sure if it was because of my computer or I was looking at the wrong branch or something.
What I learned:
Using scaffold for navigation
I can have different UI features in different files and implement them into MainActivity
Different UI features like Box and different modifiers for Text to make UI better