This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public class IslandMatrixCalculator { | |
public int calculateNumberOfIslands(int[][] matrix) { | |
int islands = 0; | |
if (matrix.length == 0) return islands; | |
for (int i=0; i<matrix.length; i++) { | |
for (int j=0; j<matrix[0].length; j++) { | |
if (matrix[i][j] == 1) { | |
removeIsland(matrix, i, j); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
.PHONY: app | |
app: | |
[Instrução] |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
disable-animations: | |
adb shell settings put global window_animation_scale 0 | |
adb shell settings put global transition_animation_scale 0 | |
adb shell settings put global animator_duration_scale 0 | |
clear-app-data: | |
adb shell pm clear com.phellipesilva.coolposts | |
run-instrumented-tests: clear-app-data disable-animations | |
./gradlew connectedAndroidTest |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[Comando]: [Comando dependencia 1] ... [Comando-dependencia N] | |
(Tab ↹)[instrução 1] | |
. | |
. | |
. | |
(Tab ↹)[instrução n] |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
disable-animations: | |
adb shell settings put global window_animation_scale 0 | |
adb shell settings put global transition_animation_scale 0 | |
adb shell settings put global animator_duration_scale 0 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
adb shell settings put global window_animation_scale 0 | |
adb shell settings put global transition_animation_scale 0 | |
adb shell settings put global animator_duration_scale 0 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
lint: | |
./gradlew lintCheckErrors --info | |
run-unit-tests: | |
./gradlew test | |
run-instrumented-tests: clear-app-data disable-animations | |
./gradlew connectedAndroidTest | |
run-all-tests: run-unit-tests build-install-app run-instrumented-tests |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
make disable-animations |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
adb shell settings put global window_animation_scale 0 | |
adb shell settings put global transition_animation_scale 0 | |
adb shell settings put global animator_duration_scale 0 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@RunWith(AndroidJUnit4::class) | |
class ChangeTextBehaviorTest { | |
@get:Rule | |
var activityRule: ActivityTestRule<MainActivity> = ActivityTestRule(MainActivity::class.java) | |
@Test | |
fun changeText_sameActivity() { | |
onView(withId(R.id.editTextUserInput)).perform(typeText("Espresso"), closeSoftKeyboard()) |