trackler 2.2.1.52 → 2.2.1.53

Sign up to get free protection for your applications and to get access to all the features.
Files changed (139) hide show
  1. checksums.yaml +4 -4
  2. data/lib/trackler/version.rb +1 -1
  3. data/problem-specifications/exercises/leap/canonical-data.json +2 -2
  4. data/tracks/cfml/tasks/FormatConfig.cfc +6 -4
  5. data/tracks/cfml/tasks/GenerateReadme.cfc +197 -0
  6. data/tracks/cfml/tasks/ScaffoldExercise.cfc +6 -0
  7. data/tracks/csharp/config.json +1 -1
  8. data/tracks/delphi/exercises/leap/uLeapTests.pas +1 -1
  9. data/tracks/fsharp/exercises/clock/Clock.fs +1 -1
  10. data/tracks/fsharp/exercises/clock/ClockTest.fs +239 -61
  11. data/tracks/fsharp/exercises/clock/Example.fs +3 -3
  12. data/tracks/fsharp/exercises/dominoes/DominoesTest.fs +29 -26
  13. data/tracks/fsharp/exercises/largest-series-product/LargestSeriesProductTest.fs +30 -15
  14. data/tracks/fsharp/exercises/leap/LeapTest.fs +2 -2
  15. data/tracks/fsharp/exercises/rectangles/Example.fs +1 -1
  16. data/tracks/fsharp/exercises/rectangles/Rectangles.fs +1 -1
  17. data/tracks/fsharp/exercises/rectangles/RectanglesTest.fs +66 -43
  18. data/tracks/fsharp/generators/Generators.fs +85 -1
  19. data/tracks/java/scripts/canonical_data_check.sh +8 -0
  20. data/tracks/kotlin/.gitignore +1 -0
  21. data/tracks/kotlin/exercises/acronym/.meta/version +1 -0
  22. data/tracks/kotlin/exercises/acronym/src/test/kotlin/AcronymTest.kt +9 -10
  23. data/tracks/kotlin/exercises/all-your-base/.meta/version +1 -1
  24. data/tracks/kotlin/exercises/all-your-base/src/test/kotlin/BaseConverterTest.kt +20 -20
  25. data/tracks/kotlin/exercises/allergies/.meta/version +1 -0
  26. data/tracks/kotlin/exercises/allergies/src/test/kotlin/AllergiesTest.kt +19 -72
  27. data/tracks/kotlin/exercises/anagram/.meta/src/reference/kotlin/Anagram.kt +7 -4
  28. data/tracks/kotlin/exercises/anagram/.meta/version +1 -0
  29. data/tracks/kotlin/exercises/anagram/src/test/kotlin/AnagramTest.kt +76 -29
  30. data/tracks/kotlin/exercises/atbash-cipher/.meta/version +1 -0
  31. data/tracks/kotlin/exercises/atbash-cipher/src/test/kotlin/AtbashTest.kt +6 -3
  32. data/tracks/kotlin/exercises/beer-song/.meta/version +1 -0
  33. data/tracks/kotlin/exercises/beer-song/src/test/kotlin/BeerSongTest.kt +21 -46
  34. data/tracks/kotlin/exercises/binary-search/.meta/version +1 -0
  35. data/tracks/kotlin/exercises/binary-search/src/test/kotlin/BinarySearchTest.kt +30 -19
  36. data/tracks/kotlin/exercises/bob/.meta/src/reference/kotlin/Bob.kt +8 -7
  37. data/tracks/kotlin/exercises/bob/.meta/version +1 -0
  38. data/tracks/kotlin/exercises/bob/src/test/kotlin/BobTest.kt +57 -15
  39. data/tracks/kotlin/exercises/bracket-push/.meta/version +1 -0
  40. data/tracks/kotlin/exercises/bracket-push/src/test/kotlin/BracketPushTest.kt +3 -1
  41. data/tracks/kotlin/exercises/collatz-conjecture/.meta/version +1 -1
  42. data/tracks/kotlin/exercises/difference-of-squares/.meta/version +1 -0
  43. data/tracks/kotlin/exercises/difference-of-squares/src/test/kotlin/SquaresTest.kt +10 -23
  44. data/tracks/kotlin/exercises/etl/.meta/src/reference/kotlin/ETL.kt +7 -1
  45. data/tracks/kotlin/exercises/etl/.meta/version +1 -0
  46. data/tracks/kotlin/exercises/etl/src/test/kotlin/ETLTest.kt +10 -10
  47. data/tracks/kotlin/exercises/flatten-array/.meta/version +1 -0
  48. data/tracks/kotlin/exercises/flatten-array/src/test/kotlin/FlattenerTest.kt +8 -16
  49. data/tracks/kotlin/exercises/gigasecond/.meta/version +1 -0
  50. data/tracks/kotlin/exercises/gigasecond/src/test/kotlin/GigasecondTest.kt +1 -1
  51. data/tracks/kotlin/exercises/hamming/.meta/src/reference/kotlin/Hamming.kt +1 -1
  52. data/tracks/kotlin/exercises/hamming/.meta/version +1 -1
  53. data/tracks/kotlin/exercises/hamming/src/test/kotlin/HammingTest.kt +4 -4
  54. data/tracks/kotlin/exercises/hello-world/.meta/version +1 -0
  55. data/tracks/kotlin/exercises/hello-world/src/test/kotlin/HelloWorldTest.kt +1 -1
  56. data/tracks/kotlin/exercises/isogram/.meta/version +1 -0
  57. data/tracks/kotlin/exercises/isogram/src/test/kotlin/IsogramTest.kt +5 -8
  58. data/tracks/kotlin/exercises/largest-series-product/.meta/src/reference/kotlin/Series.kt +2 -3
  59. data/tracks/kotlin/exercises/largest-series-product/.meta/version +1 -0
  60. data/tracks/kotlin/exercises/largest-series-product/src/test/kotlin/SeriesTest.kt +97 -0
  61. data/tracks/kotlin/exercises/leap/.meta/version +1 -0
  62. data/tracks/kotlin/exercises/leap/src/test/kotlin/LeapTest.kt +8 -26
  63. data/tracks/kotlin/exercises/list-ops/.meta/version +1 -1
  64. data/tracks/kotlin/exercises/luhn/.meta/version +1 -0
  65. data/tracks/kotlin/exercises/luhn/src/test/kotlin/LuhnTest.kt +0 -3
  66. data/tracks/kotlin/exercises/nth-prime/.meta/version +1 -0
  67. data/tracks/kotlin/exercises/nth-prime/src/test/kotlin/PrimeTest.kt +0 -2
  68. data/tracks/kotlin/exercises/nucleotide-count/.meta/src/reference/kotlin/{DNA.kt → Dna.kt} +3 -8
  69. data/tracks/kotlin/exercises/nucleotide-count/.meta/version +1 -0
  70. data/tracks/kotlin/exercises/nucleotide-count/src/test/kotlin/DnaTest.kt +48 -0
  71. data/tracks/kotlin/exercises/pangram/.meta/src/reference/kotlin/{Pangrams.kt → Pangram.kt} +1 -1
  72. data/tracks/kotlin/exercises/pangram/.meta/version +1 -1
  73. data/tracks/kotlin/exercises/pangram/src/test/kotlin/PangramTest.kt +15 -9
  74. data/tracks/kotlin/exercises/pascals-triangle/.meta/version +1 -0
  75. data/tracks/kotlin/exercises/pascals-triangle/src/test/kotlin/PascalsTriangleTest.kt +32 -14
  76. data/tracks/kotlin/exercises/perfect-numbers/.meta/src/reference/kotlin/NaturalNumber.kt +1 -1
  77. data/tracks/kotlin/exercises/perfect-numbers/.meta/version +1 -0
  78. data/tracks/kotlin/exercises/perfect-numbers/src/test/kotlin/{PerfectNumbersTest.kt → NaturalNumberTest.kt} +25 -7
  79. data/tracks/kotlin/exercises/phone-number/.meta/src/reference/kotlin/PhoneNumber.kt +15 -7
  80. data/tracks/kotlin/exercises/phone-number/.meta/version +1 -0
  81. data/tracks/kotlin/exercises/phone-number/src/test/kotlin/PhoneNumberTest.kt +46 -29
  82. data/tracks/kotlin/exercises/pig-latin/.meta/src/reference/kotlin/PigLatin.kt +2 -2
  83. data/tracks/kotlin/exercises/pig-latin/.meta/version +1 -0
  84. data/tracks/kotlin/exercises/pig-latin/src/test/kotlin/PigLatinTest.kt +21 -10
  85. data/tracks/kotlin/exercises/raindrops/.meta/version +1 -0
  86. data/tracks/kotlin/exercises/raindrops/src/test/kotlin/RaindropsTest.kt +19 -26
  87. data/tracks/kotlin/exercises/react/.meta/version +1 -0
  88. data/tracks/kotlin/exercises/react/src/test/kotlin/ReactTest.kt +11 -4
  89. data/tracks/kotlin/exercises/robot-simulator/.meta/version +1 -1
  90. data/tracks/kotlin/exercises/roman-numerals/.meta/version +1 -0
  91. data/tracks/kotlin/exercises/roman-numerals/src/test/kotlin/RomanNumeralTest.kt +1 -2
  92. data/tracks/kotlin/exercises/rotational-cipher/.meta/version +1 -1
  93. data/tracks/kotlin/exercises/rotational-cipher/src/test/kotlin/RotationalCipherTest.kt +7 -7
  94. data/tracks/kotlin/exercises/scrabble-score/.meta/src/reference/kotlin/{Scrabble.kt → ScrabbleScore.kt} +1 -1
  95. data/tracks/kotlin/exercises/scrabble-score/.meta/version +1 -0
  96. data/tracks/kotlin/exercises/scrabble-score/src/test/kotlin/ScrabbleScoreTest.kt +9 -7
  97. data/tracks/kotlin/exercises/sieve/.meta/version +1 -0
  98. data/tracks/kotlin/exercises/sieve/src/test/kotlin/SieveTest.kt +8 -0
  99. data/tracks/kotlin/exercises/space-age/.meta/version +1 -0
  100. data/tracks/kotlin/exercises/space-age/src/test/kotlin/SpaceAgeTest.kt +1 -16
  101. data/tracks/kotlin/exercises/sum-of-multiples/.meta/version +1 -0
  102. data/tracks/kotlin/exercises/sum-of-multiples/src/test/kotlin/SumOfMultiplesTest.kt +7 -7
  103. data/tracks/kotlin/exercises/triangle/.meta/version +1 -0
  104. data/tracks/kotlin/exercises/two-fer/.meta/version +1 -0
  105. data/tracks/kotlin/exercises/two-fer/src/test/kotlin/TwoferTest.kt +0 -1
  106. data/tracks/kotlin/exercises/word-count/.meta/src/reference/kotlin/WordCount.kt +6 -2
  107. data/tracks/kotlin/exercises/word-count/.meta/version +1 -0
  108. data/tracks/kotlin/exercises/word-count/src/test/kotlin/WordCountTest.kt +31 -9
  109. data/tracks/kotlin/scripts/canonical_data_check.sh +8 -0
  110. data/tracks/perl6/exercises/leap/leap.t +2 -2
  111. data/tracks/php/config.json +16 -0
  112. data/tracks/php/exercises/crypto-square/crypto-square_test.php +50 -0
  113. data/tracks/php/exercises/crypto-square/example.php +32 -0
  114. data/tracks/php/exercises/meetup/README.md +21 -0
  115. data/tracks/php/exercises/meetup/example.php +19 -0
  116. data/tracks/php/exercises/meetup/meetup_test.php +577 -0
  117. data/tracks/python/README.md +7 -5
  118. data/tracks/python/config.json +36 -27
  119. data/tracks/python/docs/TESTS.md +36 -12
  120. data/tracks/python/exercises/complex-numbers/complex_numbers_test.py +1 -1
  121. data/tracks/python/exercises/diffie-hellman/.meta/hints.md +16 -0
  122. data/tracks/python/exercises/diffie-hellman/README.md +15 -2
  123. data/tracks/python/exercises/error-handling/README.md +23 -0
  124. data/tracks/python/exercises/error-handling/error_handling.py +14 -0
  125. data/tracks/python/exercises/error-handling/error_handling_test.py +66 -0
  126. data/tracks/python/exercises/error-handling/example.py +21 -0
  127. data/tracks/python/exercises/forth/forth_test.py +1 -1
  128. data/tracks/python/exercises/isogram/isogram_test.py +5 -3
  129. data/tracks/python/exercises/leap/leap_test.py +2 -2
  130. data/tracks/python/exercises/rotational-cipher/rotational_cipher_test.py +4 -4
  131. data/tracks/python/exercises/simple-cipher/.meta/hints.md +16 -0
  132. data/tracks/python/exercises/simple-cipher/README.md +17 -0
  133. data/tracks/python/exercises/sum-of-multiples/sum_of_multiples_test.py +4 -1
  134. data/tracks/python/exercises/twelve-days/example.py +3 -3
  135. data/tracks/python/exercises/twelve-days/twelve_days.py +2 -2
  136. metadata +53 -9
  137. data/tracks/kotlin/exercises/largest-series-product/src/test/kotlin/SeriesInvalidInputTest.kt +0 -30
  138. data/tracks/kotlin/exercises/largest-series-product/src/test/kotlin/SeriesValidInputTest.kt +0 -34
  139. data/tracks/kotlin/exercises/nucleotide-count/src/test/kotlin/NucleotideTest.kt +0 -87
@@ -2,10 +2,14 @@ object WordCount {
2
2
 
3
3
  fun phrase(phrase: String): Map<String, Int> {
4
4
  val withoutPunctuation = phrase.toLowerCase().replace(Regex("[^\\w']"), " ").trim()
5
+
5
6
  val words = withoutPunctuation.split(Regex("\\s+"))
6
- val groupedWords = words.groupBy({ w -> w })
7
7
 
8
- return groupedWords.mapValues({ it.value.size })
8
+ val unquotedWords = words.map { word -> word.trim('\'') }
9
+
10
+ val groupedWords = unquotedWords.groupBy { w -> w }
11
+
12
+ return groupedWords.mapValues { it.value.size }
9
13
  }
10
14
 
11
15
  }
@@ -4,7 +4,6 @@ import kotlin.test.assertEquals
4
4
 
5
5
  class WordCountTest {
6
6
 
7
-
8
7
  @Test
9
8
  fun countOneWord() {
10
9
  val expectedWordCount = mapOf("word" to 1)
@@ -22,24 +21,39 @@ class WordCountTest {
22
21
 
23
22
  @Ignore
24
23
  @Test
25
- fun countMultipleOccurences() {
24
+ fun countMultipleOccurrences() {
26
25
  val expectedWordCount = mapOf("one" to 1, "fish" to 4, "two" to 1, "red" to 1, "blue" to 1)
27
26
 
28
27
  assertEquals(expectedWordCount, WordCount.phrase("one fish two fish red fish blue fish"))
29
28
  }
30
29
 
30
+ @Ignore
31
+ @Test
32
+ fun countCrampedList() {
33
+ val expectedWordCount = mapOf("one" to 1, "two" to 1, "three" to 1)
34
+
35
+ assertEquals(expectedWordCount, WordCount.phrase("one,two,three"))
36
+ }
37
+
38
+ @Ignore
39
+ @Test
40
+ fun countExpandedList() {
41
+ val expectedWordCount = mapOf("one" to 1, "two" to 1, "three" to 1)
42
+
43
+ assertEquals(expectedWordCount, WordCount.phrase("one,\ntwo,\nthree"))
44
+ }
45
+
31
46
  @Ignore
32
47
  @Test
33
48
  fun ignorePunctuation() {
34
49
  val expectedWordCount = mapOf("car" to 1, "carpet" to 1, "as" to 1, "java" to 1, "javascript" to 1)
35
50
 
36
- assertEquals(expectedWordCount, WordCount.phrase("car : carpet as java : javascript!!&@$%^&"))
37
-
51
+ assertEquals(expectedWordCount, WordCount.phrase("car: carpet as java: javascript!!&@\$%^&"))
38
52
  }
39
53
 
40
54
  @Ignore
41
55
  @Test
42
- fun includeNumbers() {
56
+ fun countsNumbers() {
43
57
  val expectedWordCount = mapOf("testing" to 2, "1" to 1, "2" to 1)
44
58
 
45
59
  assertEquals(expectedWordCount, WordCount.phrase("testing, 1, 2 testing"))
@@ -47,18 +61,26 @@ class WordCountTest {
47
61
 
48
62
  @Ignore
49
63
  @Test
50
- fun normalizeCase() {
51
- val expectedWordCount = mapOf("go" to 3)
64
+ fun countsCaseInsensitively() {
65
+ val expectedWordCount = mapOf("go" to 3, "stop" to 2)
52
66
 
53
- assertEquals(expectedWordCount, WordCount.phrase("go Go GO"))
67
+ assertEquals(expectedWordCount, WordCount.phrase("go Go GO Stop stop"))
54
68
  }
55
69
 
56
70
  @Ignore
57
71
  @Test
58
- fun allowApostrophes() {
72
+ fun allowsApostrophes() {
59
73
  val expectedWordCount = mapOf("first" to 1, "don't" to 2, "laugh" to 1, "then" to 1, "cry" to 1)
60
74
 
61
75
  assertEquals(expectedWordCount, WordCount.phrase("First: don't laugh. Then: don't cry."))
62
76
  }
63
77
 
78
+ @Ignore
79
+ @Test
80
+ fun allowsQuotations() {
81
+ val expectedWordCount = mapOf("joe" to 1, "can't" to 1, "tell" to 1, "between" to 1, "large" to 2, "and" to 1)
82
+
83
+ assertEquals(expectedWordCount, WordCount.phrase("Joe can't tell between 'large' and large."))
84
+ }
85
+
64
86
  }
@@ -62,6 +62,7 @@ then
62
62
  fi
63
63
 
64
64
  track_exercise_slugs=$(jq '.exercises[] | select(has("deprecated") | not) | .slug' $config_file_path | tr -d "\"")
65
+ update_needed_count=0
65
66
 
66
67
  for slug in $track_exercise_slugs
67
68
  do
@@ -88,6 +89,7 @@ do
88
89
  if ! [ -f "$track_exercise_version_file_path" ]
89
90
  then
90
91
  echo "$slug: needs update or version file (v$canonical_data_version)."
92
+ update_needed_count=$((update_needed_count + 1))
91
93
  continue
92
94
  fi
93
95
 
@@ -98,7 +100,13 @@ do
98
100
  # echo "$slug: up-to-date."
99
101
  continue
100
102
  else
103
+ update_needed_count=$((update_needed_count + 1))
101
104
  echo "$slug: needs update (v$track_data_version -> v$canonical_data_version)."
102
105
  fi
103
106
 
104
107
  done
108
+
109
+ if [ $update_needed_count -eq 1 ]
110
+ then
111
+ echo "All exercises are up to date!"
112
+ fi
@@ -29,7 +29,7 @@ is is-leap-year(.<input>), |.<expected description> for @($c-data<cases>);
29
29
 
30
30
  {
31
31
  "exercise": "leap",
32
- "version": "1.1.0",
32
+ "version": "1.2.0",
33
33
  "cases": [
34
34
  {
35
35
  "description": "year not divisible by 4: common year",
@@ -40,7 +40,7 @@ is is-leap-year(.<input>), |.<expected description> for @($c-data<cases>);
40
40
  {
41
41
  "description": "year divisible by 4, not divisible by 100: leap year",
42
42
  "property": "leapYear",
43
- "input": 2020,
43
+ "input": 1996,
44
44
  "expected": true
45
45
  },
46
46
  {
@@ -589,6 +589,14 @@
589
589
  ],
590
590
  "unlocked_by": "null"
591
591
  },
592
+ {
593
+ "uuid": "CDEAE0AF-7DBE-4D0E-ACD6-915998D273EA",
594
+ "core" : false,
595
+ "difficulty" : 1,
596
+ "slug" : "crypto-square",
597
+ "topics": [ ],
598
+ "unlocked_by": "null"
599
+ },
592
600
  {
593
601
  "uuid": "C5D81BB4-7041-4EA9-B0ED-C3A17CF3E071",
594
602
  "core" : false,
@@ -612,6 +620,14 @@
612
620
  ],
613
621
  "unlocked_by": "null"
614
622
  },
623
+ {
624
+ "uuid": "57E13615-4C88-42E1-A4AE-C2DED7A6FDB2",
625
+ "core" : false,
626
+ "difficulty" : 1,
627
+ "slug" : "meetup",
628
+ "topics": [ ],
629
+ "unlocked_by": "null"
630
+ },
615
631
  {
616
632
  "uuid": "94AA4B63-66BA-4EF4-8E27-36C146682F05",
617
633
  "core" : false,
@@ -0,0 +1,50 @@
1
+ <?php
2
+
3
+ require_once "crypto-square.php";
4
+
5
+ class CryptoSquareTest extends PHPUnit\Framework\TestCase
6
+ {
7
+ public function testEmptyPlaintextResultsInAnEmptyCiphertext()
8
+ {
9
+ $this->assertEquals(crypto_square(""), "");
10
+ }
11
+
12
+ public function testLowercase()
13
+ {
14
+ $this->markTestSkipped();
15
+ $this->assertEquals(crypto_square("A"), "a");
16
+ }
17
+
18
+ public function testRemoveSpaces()
19
+ {
20
+ $this->markTestSkipped();
21
+ $this->assertEquals(crypto_square(" b "), "b");
22
+ }
23
+
24
+ public function testRemovePunctuation()
25
+ {
26
+ $this->markTestSkipped();
27
+ $this->assertEquals(crypto_square("@1,%!"), "1");
28
+ }
29
+
30
+ public function test9CharacterPlaintextResultsIn3ChunksOf3Characters()
31
+ {
32
+ $this->markTestSkipped();
33
+ $this->assertEquals(crypto_square("This is fun!"), "tsf hiu isn");
34
+ }
35
+
36
+ public function test8CharacterPlaintextResultsIn3ChunksTheLastOneWithATrailingSpace()
37
+ {
38
+ $this->markTestSkipped();
39
+ $this->assertEquals(crypto_square("Chill out."), "clu hlt io ");
40
+ }
41
+
42
+ public function test54CharacterPlaintextResultsIn7ChunksTheLastTwoWithTrailingSpaces()
43
+ {
44
+ $this->markTestSkipped();
45
+ $this->assertEquals(
46
+ crypto_square("If man was meant to stay on the ground, god would have given us roots."),
47
+ "imtgdvs fearwer mayoogo anouuio ntnnlvt wttddes aohghn sseoau "
48
+ );
49
+ }
50
+ }
@@ -0,0 +1,32 @@
1
+ <?php
2
+
3
+ function crypto_square($plaintext)
4
+ {
5
+ $normalized = preg_replace('/\W*/', '', strtolower($plaintext));
6
+
7
+ $closestSquare = 1;
8
+ while (pow($closestSquare, 2) < strlen($normalized)) {
9
+ $closestSquare++;
10
+ }
11
+ $rows = $cols = $closestSquare;
12
+ if ($cols * ($rows - 1) >= strlen($normalized)) {
13
+ $rows = $rows - 1;
14
+ }
15
+
16
+ $encrypted = "";
17
+ $rowlist = [];
18
+ for ($i = 0; $i < $rows; $i++) {
19
+ $rowlist[] = substr($normalized, $i*$cols, $cols);
20
+ }
21
+
22
+ for ($i = 0; $i < $cols; $i++) {
23
+ for ($j = 0; $j < count($rowlist); $j++) {
24
+ $encrypted .= ($i < strlen($rowlist[$j])) ? $rowlist[$j][$i] : ' ';
25
+ }
26
+ if ($i < $cols-1) {
27
+ $encrypted .= ' ';
28
+ }
29
+ }
30
+
31
+ return $encrypted;
32
+ }
@@ -0,0 +1,21 @@
1
+ Calculate the date of meetups.
2
+
3
+ Typically meetups happen on the same day of the week. In this exercise, you will take
4
+ a description of a meetup date, and return the actual meetup date.
5
+
6
+ Examples of general descriptions are:
7
+
8
+ - the first Monday of January 2017
9
+ - the third Tuesday of January 2017
10
+ - the Wednesteenth of January 2017
11
+ - the last Thursday of January 2017
12
+
13
+ Note that "Monteenth", "Tuesteenth", etc are all made up words. There
14
+ was a meetup whose members realized that there are exactly 7 numbered days in a month that
15
+ end in '-teenth'. Therefore, one is guaranteed that each day of the week
16
+ (Monday, Tuesday, ...) will have exactly one date that is named with '-teenth'
17
+ in every month.
18
+
19
+ Given examples of a meetup dates, each containing a month, day, year, and descriptor
20
+ (first, second, teenth, etc), calculate the date of the actual meetup.
21
+ For example, if given "First Monday of January 2017", the correct meetup date is 2017/1/2
@@ -0,0 +1,19 @@
1
+ <?php
2
+
3
+ use DateTime;
4
+
5
+ function meetup_day($year, $month, $which, $weekday)
6
+ {
7
+ $monthName = (DateTime::createFromFormat("!m", $month))->format('F');
8
+ if ($which != "teenth") {
9
+ return new DateTime("$which $weekday of $monthName $year");
10
+ }
11
+
12
+ $date = new DateTime("first $weekday of $monthName $year");
13
+ while ($date->format('F') == $monthName) {
14
+ $date->modify("next $weekday");
15
+ if ($date->format('j') > 12) {
16
+ return $date;
17
+ }
18
+ }
19
+ }
@@ -0,0 +1,577 @@
1
+ <?php
2
+
3
+ require "meetup.php";
4
+
5
+ use DateTime;
6
+
7
+ class MeetupTest extends PHPUnit\Framework\TestCase
8
+ {
9
+ public function testMonteenthOfMay2013()
10
+ {
11
+ $this->assertEquals(meetup_day(2013, 5, "teenth", "Monday"), new DateTime("2013/5/13"));
12
+ }
13
+
14
+ public function testMonteenthOfAugust2013()
15
+ {
16
+ $this->markTestSkipped();
17
+ $this->assertEquals(meetup_day(2013, 8, "teenth", "Monday"), new DateTime("2013/8/19"));
18
+ }
19
+
20
+ public function testMonteenthOfSeptember2013()
21
+ {
22
+ $this->markTestSkipped();
23
+ $this->assertEquals(meetup_day(2013, 9, "teenth", "Monday"), new DateTime("2013/9/16"));
24
+ }
25
+
26
+ public function testTuesteenthOfMarch2013()
27
+ {
28
+ $this->markTestSkipped();
29
+ $this->assertEquals(meetup_day(2013, 3, "teenth", "Tuesday"), new DateTime("2013/3/19"));
30
+ }
31
+
32
+ public function testTuesteenthOfApril2013()
33
+ {
34
+ $this->markTestSkipped();
35
+ $this->assertEquals(meetup_day(2013, 4, "teenth", "Tuesday"), new DateTime("2013/4/16"));
36
+ }
37
+
38
+ public function testTuesteenthOfAugust2013()
39
+ {
40
+ $this->markTestSkipped();
41
+ $this->assertEquals(meetup_day(2013, 8, "teenth", "Tuesday"), new DateTime("2013/8/13"));
42
+ }
43
+
44
+ public function testWednesteenthOfJanuary2013()
45
+ {
46
+ $this->markTestSkipped();
47
+ $this->assertEquals(meetup_day(2013, 1, "teenth", "Wednesday"), new DateTime("2013/1/16"));
48
+ }
49
+
50
+ public function testWednesteenthOfFebruary2013()
51
+ {
52
+ $this->markTestSkipped();
53
+ $this->assertEquals(meetup_day(2013, 2, "teenth", "Wednesday"), new DateTime("2013/2/13"));
54
+ }
55
+
56
+ public function testWednesteenthOfJune2013()
57
+ {
58
+ $this->markTestSkipped();
59
+ $this->assertEquals(meetup_day(2013, 6, "teenth", "Wednesday"), new DateTime("2013/6/19"));
60
+ }
61
+
62
+ public function testThursteenthOfMay2013()
63
+ {
64
+ $this->markTestSkipped();
65
+ $this->assertEquals(meetup_day(2013, 5, "teenth", "Thursday"), new DateTime("2013/5/16"));
66
+ }
67
+
68
+ public function testThursteenthOfJune2013()
69
+ {
70
+ $this->markTestSkipped();
71
+ $this->assertEquals(meetup_day(2013, 6, "teenth", "Thursday"), new DateTime("2013/6/13"));
72
+ }
73
+
74
+ public function testThursteenthOfSeptember2013()
75
+ {
76
+ $this->markTestSkipped();
77
+ $this->assertEquals(meetup_day(2013, 9, "teenth", "Thursday"), new DateTime("2013/9/19"));
78
+ }
79
+
80
+ public function testFriteenthOfApril2013()
81
+ {
82
+ $this->markTestSkipped();
83
+ $this->assertEquals(meetup_day(2013, 4, "teenth", "Friday"), new DateTime("2013/4/19"));
84
+ }
85
+
86
+ public function testFriteenthOfAugust2013()
87
+ {
88
+ $this->markTestSkipped();
89
+ $this->assertEquals(meetup_day(2013, 8, "teenth", "Friday"), new DateTime("2013/8/16"));
90
+ }
91
+
92
+ public function testFriteenthOfSeptember2013()
93
+ {
94
+ $this->markTestSkipped();
95
+ $this->assertEquals(meetup_day(2013, 9, "teenth", "Friday"), new DateTime("2013/9/13"));
96
+ }
97
+
98
+ public function testSaturteenthOfFebruary2013()
99
+ {
100
+ $this->markTestSkipped();
101
+ $this->assertEquals(meetup_day(2013, 2, "teenth", "Saturday"), new DateTime("2013/2/16"));
102
+ }
103
+
104
+ public function testSaturteenthOfApril2013()
105
+ {
106
+ $this->markTestSkipped();
107
+ $this->assertEquals(meetup_day(2013, 4, "teenth", "Saturday"), new DateTime("2013/4/13"));
108
+ }
109
+
110
+ public function testSaturteenthOfOctober2013()
111
+ {
112
+ $this->markTestSkipped();
113
+ $this->assertEquals(meetup_day(2013, 10, "teenth", "Saturday"), new DateTime("2013/10/19"));
114
+ }
115
+
116
+ public function testSunteenthOfMay2013()
117
+ {
118
+ $this->markTestSkipped();
119
+ $this->assertEquals(meetup_day(2013, 5, "teenth", "Sunday"), new DateTime("2013/5/19"));
120
+ }
121
+
122
+ public function testSunteenthOfJune2013()
123
+ {
124
+ $this->markTestSkipped();
125
+ $this->assertEquals(meetup_day(2013, 6, "teenth", "Sunday"), new DateTime("2013/6/16"));
126
+ }
127
+
128
+ public function testSunteenthOfOctober2013()
129
+ {
130
+ $this->markTestSkipped();
131
+ $this->assertEquals(meetup_day(2013, 10, "teenth", "Sunday"), new DateTime("2013/10/13"));
132
+ }
133
+
134
+ public function testFirstMondayOfMarch2013()
135
+ {
136
+ $this->markTestSkipped();
137
+ $this->assertEquals(meetup_day(2013, 3, "first", "Monday"), new DateTime("2013/3/4"));
138
+ }
139
+
140
+ public function testFirstMondayOfApril2013()
141
+ {
142
+ $this->markTestSkipped();
143
+ $this->assertEquals(meetup_day(2013, 4, "first", "Monday"), new DateTime("2013/4/1"));
144
+ }
145
+
146
+ public function testFirstTuesdayOfMay2013()
147
+ {
148
+ $this->markTestSkipped();
149
+ $this->assertEquals(meetup_day(2013, 5, "first", "Tuesday"), new DateTime("2013/5/7"));
150
+ }
151
+
152
+ public function testFirstTuesdayOfJune2013()
153
+ {
154
+ $this->markTestSkipped();
155
+ $this->assertEquals(meetup_day(2013, 6, "first", "Tuesday"), new DateTime("2013/6/4"));
156
+ }
157
+
158
+ public function testFirstWednesdayOfJuly2013()
159
+ {
160
+ $this->markTestSkipped();
161
+ $this->assertEquals(meetup_day(2013, 7, "first", "Wednesday"), new DateTime("2013/7/3"));
162
+ }
163
+
164
+ public function testFirstWednesdayOfAugust2013()
165
+ {
166
+ $this->markTestSkipped();
167
+ $this->assertEquals(meetup_day(2013, 8, "first", "Wednesday"), new DateTime("2013/8/7"));
168
+ }
169
+
170
+ public function testFirstThursdayOfSeptember2013()
171
+ {
172
+ $this->markTestSkipped();
173
+ $this->assertEquals(meetup_day(2013, 9, "first", "Thursday"), new DateTime("2013/9/5"));
174
+ }
175
+
176
+ public function testFirstThursdayOfOctober2013()
177
+ {
178
+ $this->markTestSkipped();
179
+ $this->assertEquals(meetup_day(2013, 10, "first", "Thursday"), new DateTime("2013/10/3"));
180
+ }
181
+
182
+ public function testFirstFridayOfNovember2013()
183
+ {
184
+ $this->markTestSkipped();
185
+ $this->assertEquals(meetup_day(2013, 11, "first", "Friday"), new DateTime("2013/11/1"));
186
+ }
187
+
188
+ public function testFirstFridayOfDecember2013()
189
+ {
190
+ $this->markTestSkipped();
191
+ $this->assertEquals(meetup_day(2013, 12, "first", "Friday"), new DateTime("2013/12/6"));
192
+ }
193
+
194
+ public function testFirstSaturdayOfJanuary2013()
195
+ {
196
+ $this->markTestSkipped();
197
+ $this->assertEquals(meetup_day(2013, 1, "first", "Saturday"), new DateTime("2013/1/5"));
198
+ }
199
+
200
+ public function testFirstSaturdayOfFebruary2013()
201
+ {
202
+ $this->markTestSkipped();
203
+ $this->assertEquals(meetup_day(2013, 2, "first", "Saturday"), new DateTime("2013/2/2"));
204
+ }
205
+
206
+ public function testFirstSundayOfMarch2013()
207
+ {
208
+ $this->markTestSkipped();
209
+ $this->assertEquals(meetup_day(2013, 3, "first", "Sunday"), new DateTime("2013/3/3"));
210
+ }
211
+
212
+ public function testFirstSundayOfApril2013()
213
+ {
214
+ $this->markTestSkipped();
215
+ $this->assertEquals(meetup_day(2013, 4, "first", "Sunday"), new DateTime("2013/4/7"));
216
+ }
217
+
218
+ public function testSecondMondayOfMarch2013()
219
+ {
220
+ $this->markTestSkipped();
221
+ $this->assertEquals(meetup_day(2013, 3, "second", "Monday"), new DateTime("2013/3/11"));
222
+ }
223
+
224
+ public function testSecondMondayOfApril2013()
225
+ {
226
+ $this->markTestSkipped();
227
+ $this->assertEquals(meetup_day(2013, 4, "second", "Monday"), new DateTime("2013/4/8"));
228
+ }
229
+
230
+ public function testSecondTuesdayOfMay2013()
231
+ {
232
+ $this->markTestSkipped();
233
+ $this->assertEquals(meetup_day(2013, 5, "second", "Tuesday"), new DateTime("2013/5/14"));
234
+ }
235
+
236
+ public function testSecondTuesdayOfJune2013()
237
+ {
238
+ $this->markTestSkipped();
239
+ $this->assertEquals(meetup_day(2013, 6, "second", "Tuesday"), new DateTime("2013/6/11"));
240
+ }
241
+
242
+ public function testSecondWednesdayOfJuly2013()
243
+ {
244
+ $this->markTestSkipped();
245
+ $this->assertEquals(meetup_day(2013, 7, "second", "Wednesday"), new DateTime("2013/7/10"));
246
+ }
247
+
248
+ public function testSecondWednesdayOfAugust2013()
249
+ {
250
+ $this->markTestSkipped();
251
+ $this->assertEquals(meetup_day(2013, 8, "second", "Wednesday"), new DateTime("2013/8/14"));
252
+ }
253
+
254
+ public function testSecondThursdayOfSeptember2013()
255
+ {
256
+ $this->markTestSkipped();
257
+ $this->assertEquals(meetup_day(2013, 9, "second", "Thursday"), new DateTime("2013/9/12"));
258
+ }
259
+
260
+ public function testSecondThursdayOfOctober2013()
261
+ {
262
+ $this->markTestSkipped();
263
+ $this->assertEquals(meetup_day(2013, 10, "second", "Thursday"), new DateTime("2013/10/10"));
264
+ }
265
+
266
+ public function testSecondFridayOfNovember2013()
267
+ {
268
+ $this->markTestSkipped();
269
+ $this->assertEquals(meetup_day(2013, 11, "second", "Friday"), new DateTime("2013/11/8"));
270
+ }
271
+
272
+ public function testSecondFridayOfDecember2013()
273
+ {
274
+ $this->markTestSkipped();
275
+ $this->assertEquals(meetup_day(2013, 12, "second", "Friday"), new DateTime("2013/12/13"));
276
+ }
277
+
278
+ public function testSecondSaturdayOfJanuary2013()
279
+ {
280
+ $this->markTestSkipped();
281
+ $this->assertEquals(meetup_day(2013, 1, "second", "Saturday"), new DateTime("2013/1/12"));
282
+ }
283
+
284
+ public function testSecondSaturdayOfFebruary2013()
285
+ {
286
+ $this->markTestSkipped();
287
+ $this->assertEquals(meetup_day(2013, 2, "second", "Saturday"), new DateTime("2013/2/9"));
288
+ }
289
+
290
+ public function testSecondSundayOfMarch2013()
291
+ {
292
+ $this->markTestSkipped();
293
+ $this->assertEquals(meetup_day(2013, 3, "second", "Sunday"), new DateTime("2013/3/10"));
294
+ }
295
+
296
+ public function testSecondSundayOfApril2013()
297
+ {
298
+ $this->markTestSkipped();
299
+ $this->assertEquals(meetup_day(2013, 4, "second", "Sunday"), new DateTime("2013/4/14"));
300
+ }
301
+
302
+ public function testThirdMondayOfMarch2013()
303
+ {
304
+ $this->markTestSkipped();
305
+ $this->assertEquals(meetup_day(2013, 3, "third", "Monday"), new DateTime("2013/3/18"));
306
+ }
307
+
308
+ public function testThirdMondayOfApril2013()
309
+ {
310
+ $this->markTestSkipped();
311
+ $this->assertEquals(meetup_day(2013, 4, "third", "Monday"), new DateTime("2013/4/15"));
312
+ }
313
+
314
+ public function testThirdTuesdayOfMay2013()
315
+ {
316
+ $this->markTestSkipped();
317
+ $this->assertEquals(meetup_day(2013, 5, "third", "Tuesday"), new DateTime("2013/5/21"));
318
+ }
319
+
320
+ public function testThirdTuesdayOfJune2013()
321
+ {
322
+ $this->markTestSkipped();
323
+ $this->assertEquals(meetup_day(2013, 6, "third", "Tuesday"), new DateTime("2013/6/18"));
324
+ }
325
+
326
+ public function testThirdWednesdayOfJuly2013()
327
+ {
328
+ $this->markTestSkipped();
329
+ $this->assertEquals(meetup_day(2013, 7, "third", "Wednesday"), new DateTime("2013/7/17"));
330
+ }
331
+
332
+ public function testThirdWednesdayOfAugust2013()
333
+ {
334
+ $this->markTestSkipped();
335
+ $this->assertEquals(meetup_day(2013, 8, "third", "Wednesday"), new DateTime("2013/8/21"));
336
+ }
337
+
338
+ public function testThirdThursdayOfSeptember2013()
339
+ {
340
+ $this->markTestSkipped();
341
+ $this->assertEquals(meetup_day(2013, 9, "third", "Thursday"), new DateTime("2013/9/19"));
342
+ }
343
+
344
+ public function testThirdThursdayOfOctober2013()
345
+ {
346
+ $this->markTestSkipped();
347
+ $this->assertEquals(meetup_day(2013, 10, "third", "Thursday"), new DateTime("2013/10/17"));
348
+ }
349
+
350
+ public function testThirdFridayOfNovember2013()
351
+ {
352
+ $this->markTestSkipped();
353
+ $this->assertEquals(meetup_day(2013, 11, "third", "Friday"), new DateTime("2013/11/15"));
354
+ }
355
+
356
+ public function testThirdFridayOfDecember2013()
357
+ {
358
+ $this->markTestSkipped();
359
+ $this->assertEquals(meetup_day(2013, 12, "third", "Friday"), new DateTime("2013/12/20"));
360
+ }
361
+
362
+ public function testThirdSaturdayOfJanuary2013()
363
+ {
364
+ $this->markTestSkipped();
365
+ $this->assertEquals(meetup_day(2013, 1, "third", "Saturday"), new DateTime("2013/1/19"));
366
+ }
367
+
368
+ public function testThirdSaturdayOfFebruary2013()
369
+ {
370
+ $this->markTestSkipped();
371
+ $this->assertEquals(meetup_day(2013, 2, "third", "Saturday"), new DateTime("2013/2/16"));
372
+ }
373
+
374
+ public function testThirdSundayOfMarch2013()
375
+ {
376
+ $this->markTestSkipped();
377
+ $this->assertEquals(meetup_day(2013, 3, "third", "Sunday"), new DateTime("2013/3/17"));
378
+ }
379
+
380
+ public function testThirdSundayOfApril2013()
381
+ {
382
+ $this->markTestSkipped();
383
+ $this->assertEquals(meetup_day(2013, 4, "third", "Sunday"), new DateTime("2013/4/21"));
384
+ }
385
+
386
+ public function testFourthMondayOfMarch2013()
387
+ {
388
+ $this->markTestSkipped();
389
+ $this->assertEquals(meetup_day(2013, 3, "fourth", "Monday"), new DateTime("2013/3/25"));
390
+ }
391
+
392
+ public function testFourthMondayOfApril2013()
393
+ {
394
+ $this->markTestSkipped();
395
+ $this->assertEquals(meetup_day(2013, 4, "fourth", "Monday"), new DateTime("2013/4/22"));
396
+ }
397
+
398
+ public function testFourthTuesdayOfMay2013()
399
+ {
400
+ $this->markTestSkipped();
401
+ $this->assertEquals(meetup_day(2013, 5, "fourth", "Tuesday"), new DateTime("2013/5/28"));
402
+ }
403
+
404
+ public function testFourthTuesdayOfJune2013()
405
+ {
406
+ $this->markTestSkipped();
407
+ $this->assertEquals(meetup_day(2013, 6, "fourth", "Tuesday"), new DateTime("2013/6/25"));
408
+ }
409
+
410
+ public function testFourthWednesdayOfJuly2013()
411
+ {
412
+ $this->markTestSkipped();
413
+ $this->assertEquals(meetup_day(2013, 7, "fourth", "Wednesday"), new DateTime("2013/7/24"));
414
+ }
415
+
416
+ public function testFourthWednesdayOfAugust2013()
417
+ {
418
+ $this->markTestSkipped();
419
+ $this->assertEquals(meetup_day(2013, 8, "fourth", "Wednesday"), new DateTime("2013/8/28"));
420
+ }
421
+
422
+ public function testFourthThursdayOfSeptember2013()
423
+ {
424
+ $this->markTestSkipped();
425
+ $this->assertEquals(meetup_day(2013, 9, "fourth", "Thursday"), new DateTime("2013/9/26"));
426
+ }
427
+
428
+ public function testFourthThursdayOfOctober2013()
429
+ {
430
+ $this->markTestSkipped();
431
+ $this->assertEquals(meetup_day(2013, 10, "fourth", "Thursday"), new DateTime("2013/10/24"));
432
+ }
433
+
434
+ public function testFourthFridayOfNovember2013()
435
+ {
436
+ $this->markTestSkipped();
437
+ $this->assertEquals(meetup_day(2013, 11, "fourth", "Friday"), new DateTime("2013/11/22"));
438
+ }
439
+
440
+ public function testFourthFridayOfDecember2013()
441
+ {
442
+ $this->markTestSkipped();
443
+ $this->assertEquals(meetup_day(2013, 12, "fourth", "Friday"), new DateTime("2013/12/27"));
444
+ }
445
+
446
+ public function testFourthSaturdayOfJanuary2013()
447
+ {
448
+ $this->markTestSkipped();
449
+ $this->assertEquals(meetup_day(2013, 1, "fourth", "Saturday"), new DateTime("2013/1/26"));
450
+ }
451
+
452
+ public function testFourthSaturdayOfFebruary2013()
453
+ {
454
+ $this->markTestSkipped();
455
+ $this->assertEquals(meetup_day(2013, 2, "fourth", "Saturday"), new DateTime("2013/2/23"));
456
+ }
457
+
458
+ public function testFourthSundayOfMarch2013()
459
+ {
460
+ $this->markTestSkipped();
461
+ $this->assertEquals(meetup_day(2013, 3, "fourth", "Sunday"), new DateTime("2013/3/24"));
462
+ }
463
+
464
+ public function testFourthSundayOfApril2013()
465
+ {
466
+ $this->markTestSkipped();
467
+ $this->assertEquals(meetup_day(2013, 4, "fourth", "Sunday"), new DateTime("2013/4/28"));
468
+ }
469
+
470
+ public function testLastMondayOfMarch2013()
471
+ {
472
+ $this->markTestSkipped();
473
+ $this->assertEquals(meetup_day(2013, 3, "last", "Monday"), new DateTime("2013/3/25"));
474
+ }
475
+
476
+ public function testLastMondayOfApril2013()
477
+ {
478
+ $this->markTestSkipped();
479
+ $this->assertEquals(meetup_day(2013, 4, "last", "Monday"), new DateTime("2013/4/29"));
480
+ }
481
+
482
+ public function testLastTuesdayOfMay2013()
483
+ {
484
+ $this->markTestSkipped();
485
+ $this->assertEquals(meetup_day(2013, 5, "last", "Tuesday"), new DateTime("2013/5/28"));
486
+ }
487
+
488
+ public function testLastTuesdayOfJune2013()
489
+ {
490
+ $this->markTestSkipped();
491
+ $this->assertEquals(meetup_day(2013, 6, "last", "Tuesday"), new DateTime("2013/6/25"));
492
+ }
493
+
494
+ public function testLastWednesdayOfJuly2013()
495
+ {
496
+ $this->markTestSkipped();
497
+ $this->assertEquals(meetup_day(2013, 7, "last", "Wednesday"), new DateTime("2013/7/31"));
498
+ }
499
+
500
+ public function testLastWednesdayOfAugust2013()
501
+ {
502
+ $this->markTestSkipped();
503
+ $this->assertEquals(meetup_day(2013, 8, "last", "Wednesday"), new DateTime("2013/8/28"));
504
+ }
505
+
506
+ public function testLastThursdayOfSeptember2013()
507
+ {
508
+ $this->markTestSkipped();
509
+ $this->assertEquals(meetup_day(2013, 9, "last", "Thursday"), new DateTime("2013/9/26"));
510
+ }
511
+
512
+ public function testLastThursdayOfOctober2013()
513
+ {
514
+ $this->markTestSkipped();
515
+ $this->assertEquals(meetup_day(2013, 10, "last", "Thursday"), new DateTime("2013/10/31"));
516
+ }
517
+
518
+ public function testLastFridayOfNovember2013()
519
+ {
520
+ $this->markTestSkipped();
521
+ $this->assertEquals(meetup_day(2013, 11, "last", "Friday"), new DateTime("2013/11/29"));
522
+ }
523
+
524
+ public function testLastFridayOfDecember2013()
525
+ {
526
+ $this->markTestSkipped();
527
+ $this->assertEquals(meetup_day(2013, 12, "last", "Friday"), new DateTime("2013/12/27"));
528
+ }
529
+
530
+ public function testLastSaturdayOfJanuary2013()
531
+ {
532
+ $this->markTestSkipped();
533
+ $this->assertEquals(meetup_day(2013, 1, "last", "Saturday"), new DateTime("2013/1/26"));
534
+ }
535
+
536
+ public function testLastSaturdayOfFebruary2013()
537
+ {
538
+ $this->markTestSkipped();
539
+ $this->assertEquals(meetup_day(2013, 2, "last", "Saturday"), new DateTime("2013/2/23"));
540
+ }
541
+
542
+ public function testLastSundayOfMarch2013()
543
+ {
544
+ $this->markTestSkipped();
545
+ $this->assertEquals(meetup_day(2013, 3, "last", "Sunday"), new DateTime("2013/3/31"));
546
+ }
547
+
548
+ public function testLastSundayOfApril2013()
549
+ {
550
+ $this->markTestSkipped();
551
+ $this->assertEquals(meetup_day(2013, 4, "last", "Sunday"), new DateTime("2013/4/28"));
552
+ }
553
+
554
+ public function testLastWednesdayOfFebruary2012()
555
+ {
556
+ $this->markTestSkipped();
557
+ $this->assertEquals(meetup_day(2012, 2, "last", "Wednesday"), new DateTime("2012/2/29"));
558
+ }
559
+
560
+ public function testLastWednesdayOfDecember2014()
561
+ {
562
+ $this->markTestSkipped();
563
+ $this->assertEquals(meetup_day(2014, 12, "last", "Wednesday"), new DateTime("2014/12/31"));
564
+ }
565
+
566
+ public function testLastSundayOfFebruary2015()
567
+ {
568
+ $this->markTestSkipped();
569
+ $this->assertEquals(meetup_day(2015, 2, "last", "Sunday"), new DateTime("2015/2/22"));
570
+ }
571
+
572
+ public function testFirstFridayOfDecember2012()
573
+ {
574
+ $this->markTestSkipped();
575
+ $this->assertEquals(meetup_day(2012, 12, "first", "Friday"), new DateTime("2012/12/7"));
576
+ }
577
+ }