From 9f2113b02dd5aa1979755bff6d582dc76f021969 Mon Sep 17 00:00:00 2001 From: Kamila Babayeva Date: Mon, 23 May 2022 20:36:13 +0200 Subject: [PATCH 01/14] ScoreBoardFragmentTest: uncomment --- .../java/ch/sdp/vibester/fragment/ScoreBoardFragmentTest.kt | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/app/src/androidTest/java/ch/sdp/vibester/fragment/ScoreBoardFragmentTest.kt b/app/src/androidTest/java/ch/sdp/vibester/fragment/ScoreBoardFragmentTest.kt index 91d6bf652..0a69bd675 100644 --- a/app/src/androidTest/java/ch/sdp/vibester/fragment/ScoreBoardFragmentTest.kt +++ b/app/src/androidTest/java/ch/sdp/vibester/fragment/ScoreBoardFragmentTest.kt @@ -1,5 +1,5 @@ package ch.sdp.vibester.fragment -/* + import androidx.recyclerview.widget.RecyclerView import androidx.test.espresso.Espresso.onView import androidx.test.espresso.action.ViewActions.click @@ -102,5 +102,3 @@ class ScoreBoardFragmentTest { onView(withId(R.id.scoreboard_btsButton)).perform(click()) } } - - */ \ No newline at end of file From a8e145fcc3d21207bb31bce23d306e0a0003faba Mon Sep 17 00:00:00 2001 From: Kamila Babayeva Date: Mon, 23 May 2022 20:36:36 +0200 Subject: [PATCH 02/14] GameSetupFragment: put code in onViewCreated --- .../java/ch/sdp/vibester/fragment/GameSetupFragment.kt | 10 +++------- 1 file changed, 3 insertions(+), 7 deletions(-) diff --git a/app/src/main/java/ch/sdp/vibester/fragment/GameSetupFragment.kt b/app/src/main/java/ch/sdp/vibester/fragment/GameSetupFragment.kt index c573cd6c8..105b32268 100644 --- a/app/src/main/java/ch/sdp/vibester/fragment/GameSetupFragment.kt +++ b/app/src/main/java/ch/sdp/vibester/fragment/GameSetupFragment.kt @@ -42,12 +42,9 @@ class GameSetupFragment : Fragment(), View.OnClickListener, AdapterView.OnItemSe // TODO: OFFLINE private var hasInternet: Boolean = true - override fun onCreateView( - inflater: LayoutInflater, container: ViewGroup?, - savedInstanceState: Bundle? - ): View? { - val view = inflater.inflate(R.layout.fragment_game_setup, container, false) - val ctx = inflater.context + override fun onViewCreated(view: View, savedInstanceState: Bundle?) { + super.onViewCreated(view, savedInstanceState) + val ctx = view.context view.findViewById