Skip to content

Commit

Permalink
Merge branch 'develop'
Browse files Browse the repository at this point in the history
  • Loading branch information
josdem committed Apr 11, 2024
2 parents 72b7e8c + 27a6c7a commit 524a86c
Show file tree
Hide file tree
Showing 4 changed files with 9 additions and 9 deletions.
2 changes: 1 addition & 1 deletion simple-algorithms/counting-uppercase/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ plugins {
id 'java'
}

def junitJupiterVersion = '5.7.0'
def junitJupiterVersion = '5.10.2'

group 'com.josdem.kata'
version '1.0-SNAPSHOT'
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
distributionBase=GRADLE_USER_HOME
distributionPath=wrapper/dists
distributionUrl=https\://services.gradle.org/distributions/gradle-7.4.2-bin.zip
distributionUrl=https\://services.gradle.org/distributions/gradle-8.5-bin.zip
zipStoreBase=GRADLE_USER_HOME
zipStorePath=wrapper/dists
Original file line number Diff line number Diff line change
Expand Up @@ -2,11 +2,11 @@

public class UppercaseCounter {

public int count(String message) {
return (int) message.chars().filter(it -> it >= 65 && it <= 90).count();
}
public int count(String message) {
return message.length();
}

public boolean hasSpace(String message) {
return message.contains(" ");
}
public boolean hasSpace(String message) {
return message.isEmpty();
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@

class CountingUppercaseTest {

private UppercaseCounter uppercaseCounter = new UppercaseCounter();
private final UppercaseCounter uppercaseCounter = new UppercaseCounter();

@Test
@DisplayName("count three uppercase")
Expand Down

0 comments on commit 524a86c

Please sign in to comment.