Skip to content

Commit

Permalink
Sync tests for practice exercise resistor color duo (#2612)
Browse files Browse the repository at this point in the history
  • Loading branch information
manumafe98 authored Dec 30, 2023
1 parent 2727382 commit 3cb37cd
Show file tree
Hide file tree
Showing 2 changed files with 34 additions and 5 deletions.
19 changes: 16 additions & 3 deletions exercises/practice/resistor-color-duo/.meta/tests.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,13 @@
# This is an auto-generated file. Regular comments will be removed when this
# file is regenerated. Regenerating will not touch any manually added keys,
# so comments can be added in a "comment" key.
# This is an auto-generated file.
#
# Regenerating this file via `configlet sync` will:
# - Recreate every `description` key/value pair
# - Recreate every `reimplements` key/value pair, where they exist in problem-specifications
# - Remove any `include = true` key/value pair (an omitted `include` key implies inclusion)
# - Preserve any other key/value pair
#
# As user-added comments (using the # character) will be removed when this file
# is regenerated, comments can be added via a `comment` key.

[ce11995a-5b93-4950-a5e9-93423693b2fc]
description = "Brown and black"
Expand All @@ -11,8 +18,14 @@ description = "Blue and grey"
[f1886361-fdfd-4693-acf8-46726fe24e0c]
description = "Yellow and violet"

[b7a6cbd2-ae3c-470a-93eb-56670b305640]
description = "White and red"

[77a8293d-2a83-4016-b1af-991acc12b9fe]
description = "Orange and orange"

[0c4fb44f-db7c-4d03-afa8-054350f156a8]
description = "Ignore additional colors"

[4a8ceec5-0ab4-4904-88a4-daf953a5e818]
description = "Black and brown, one-digit"
Original file line number Diff line number Diff line change
Expand Up @@ -30,8 +30,8 @@ public void testBlueAndGrey() {
@Ignore("Remove to run test")
@Test
public void testYellowAndViolet() {
assertThat(resistorColorDuo.value(
new String[]{ "yellow", "violet" })
assertThat(
resistorColorDuo.value(new String[]{ "yellow", "violet" })
).isEqualTo(47);
}

Expand All @@ -42,6 +42,22 @@ public void testOrangeAndOrange() {
resistorColorDuo.value(new String[]{ "orange", "orange" })
).isEqualTo(33);
}

@Ignore("Remove to run test")
@Test
public void testWhiteAndRed() {
assertThat(
resistorColorDuo.value(new String[]{ "white", "red" })
).isEqualTo(92);
}

@Ignore("Remove to run test")
@Test
public void testBlackAndBrownOneDigit() {
assertThat(
resistorColorDuo.value(new String[]{ "black", "brown" })
).isEqualTo(1);
}

@Ignore("Remove to run test")
@Test
Expand Down

0 comments on commit 3cb37cd

Please sign in to comment.