Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Better exercise var name in tests #627

Open
wants to merge 22 commits into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
22 commits
Select commit Hold shift + click to select a range
077ee14
Exercise generator can regenerate existing exercises.
Bajger Apr 12, 2024
eb4e15f
fixed initializaiton of regenerating flag, fixed condition to produce…
Bajger Apr 17, 2024
5bfdd5e
Update class documentation of exercism test generator.
Bajger May 9, 2024
3181ef0
Update contributing guideline
Bajger May 9, 2024
c61991e
Make exercise generator more robust by testing required content of ex…
Bajger May 22, 2024
a702bd4
Refactored exercise source code generator to work just for given exer…
Bajger May 29, 2024
0bae754
Added checking and fetching of configlet, set repository path as defa…
Bajger Jun 11, 2024
b9dede8
improved test description for fetching configlet
Bajger Jun 12, 2024
a81a6a2
Use default root of configlet directory from git repository. If not …
Bajger Jun 12, 2024
4c78c5a
Fixed path in failing test.
Bajger Jun 12, 2024
81d92a5
Updated configlet metadata update, tests update, change in referencin…
Bajger Jun 13, 2024
e0e9530
Added update config file method on ExercismConfigGenerator (work in …
Bajger Feb 5, 2025
22e038c
Removed is followedBy is unlockedBy (with tests) - not used anymore i…
Bajger Feb 5, 2025
d32e2ef
Removed concept of core and bonus exercises, removed autoApproved, de…
Bajger Feb 6, 2025
0e3ede5
Removed unlockedBy attribute from exercise.
Bajger Feb 6, 2025
0a75c65
Adjusted collection of v3 attributes that should be serialized to JSO…
Bajger Feb 7, 2025
7289102
Merge branch 'main' into better-exercise-var-name-in-tests
Bajger Feb 7, 2025
bb73e6e
Updated config.json generation according to v3, added unit tests for it.
Bajger Feb 10, 2025
d04c790
Fixed typo practise vs practice (new).
Bajger Feb 10, 2025
e5de47f
Changed default path for all generators -> repository path is the def…
Bajger Feb 10, 2025
07c3e0e
Refactored exercise configuration in config.json into own method.
Bajger Feb 10, 2025
98ba4d1
Fixed 'test_runner' key in config.json.
Bajger Feb 10, 2025
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 0 additions & 1 deletion dev/src/Exercise@Acronym/AcronymTest.class.st
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,6 @@ Class {
{ #category : #config }
AcronymTest class >> exercise [
^(self createExerciseAfter: ReverseStringTest)
isCore: false;
difficulty: 2;
topics: #('strings' 'iteration' 'parsing');
yourself
Expand Down
1 change: 0 additions & 1 deletion dev/src/Exercise@Allergies/AllergiesTest.class.st
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,6 @@ AllergiesTest class >> exercise [
"Answer the configured exercise meta data for this exercise, an ExercismExercise"

^(self createExerciseAfter: GrainsTest)
isCore: true;
difficulty: 3;
topics: #('bitwise_operations' 'filtering');
yourself
Expand Down
1 change: 0 additions & 1 deletion dev/src/Exercise@Anagram/AnagramTest.class.st
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,6 @@ AnagramTest class >> exercise [
"Answer the configured exercise meta data for this exercise, an ExercismExercise"

^(self createExerciseAfter: IsogramTest)
isCore: false;
difficulty: 3;
topics: #('strings' 'filtering');
yourself
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,6 @@ Class {
{ #category : #config }
ArmstrongNumbersTest class >> exercise [
^ (self createExerciseAfter: TwoFerTest)
isCore: false;
difficulty: 2;
topics: #('math' 'integers');
yourself
Expand Down
1 change: 0 additions & 1 deletion dev/src/Exercise@AtbashCipher/AtbashCipherTest.class.st
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,6 @@ AtbashCipherTest class >> exercise [
"Answer the configured exercise meta data for this exercise, an ExercismExercise"

^ (self createExerciseAfter: GrainsTest)
isCore: false;
difficulty: 3;
topics: #('algorithms' 'strings' 'transforming' 'cryptography');
yourself
Expand Down
1 change: 0 additions & 1 deletion dev/src/Exercise@Binary/BinaryTest.class.st
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,6 @@ BinaryTest class >> exercise [
"Answer the configured exercise meta data for this exercise, an ExercismExercise"

^(self createExerciseAfter: IsogramTest )
isCore: false;
difficulty: 3;
topics: #('strings' 'iteration' 'math');
yourself
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -67,8 +67,6 @@ Class {
BinarySearchTreeTest class >> exercise [

^(ExercismExercise for: self)
isCore: false;
isAutoApproved: true;
difficulty: 6;
topics: #('algorithms' 'conditionals' 'data_structures' 'recursion');
yourself
Expand Down
1 change: 0 additions & 1 deletion dev/src/Exercise@Bowling/BowlingTest.class.st
Original file line number Diff line number Diff line change
Expand Up @@ -80,7 +80,6 @@ BowlingTest class >> exercise [
"Answer the configured exercise meta data for this exercise, an ExercismExercise"

^(self createExerciseAfter: GradeSchoolTest )
isCore: false;
difficulty: 5;
topics: #('conditionals' 'object_oriented_programming' 'algorithms');
yourself
Expand Down
2 changes: 0 additions & 2 deletions dev/src/Exercise@CircularBuffer/CircularBufferTest.class.st
Original file line number Diff line number Diff line change
Expand Up @@ -61,8 +61,6 @@ Class {
CircularBufferTest class >> exercise [

^(ExercismExercise for: self)
isCore: false;
isAutoApproved: true;
difficulty: 5;
topics: #('arrays' 'conditionals' 'data_structures' 'exception_handling' 'lists' 'list-methods');
yourself
Expand Down
1 change: 0 additions & 1 deletion dev/src/Exercise@Clock/ClockTest.class.st
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,6 @@ ClockTest class >> exercise [
"Answer the configured exercise meta data for this exercise, an ExercismExercise"

^(self createExerciseAfter: LeapTest)
isCore: false;
difficulty: 2;
topics: #('math' 'classes' 'structural_equality');
yourself
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,6 @@ CollatzConjectureTest class >> exercise [
"Answer the configured exercise meta data for this exercise, an ExercismExercise"

^ (self createExerciseAfter: GrainsTest)
isCore: false;
difficulty: 2;
topics:
#('recursion' 'control_flow' 'math');
Expand Down
1 change: 0 additions & 1 deletion dev/src/Exercise@Darts/DartsTest.class.st
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,6 @@ DartsTest class >> exercise [
"Answer the configured exercise meta data for this exercise, an ExercismExercise"

^ (self createExerciseAfter: LeapTest)
isCore: false;
difficulty: 2;
topics: #('conditionals' 'math');
yourself
Expand Down
1 change: 0 additions & 1 deletion dev/src/Exercise@Diamond/DiamondTest.class.st
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,6 @@ DiamondTest class >> exercise [
"Answer the configured exercise meta data for this exercise, an ExercismExercise"

^(self createExerciseAfter: ReverseStringTest )
isCore: false;
difficulty: 3;
topics: #('strings' 'algorithms' 'lists' 'text_formatting');
yourself
Expand Down
1 change: 0 additions & 1 deletion dev/src/Exercise@Die/DieTest.class.st
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,6 @@ DieTest class >> exercise [
"Answer the configured exercise meta data for this exercise, an ExercismExercise"

^(ExercismExercise for: self)
isCore: false;
difficulty: 1;
topics: #('math');
yourself
Expand Down
1 change: 0 additions & 1 deletion dev/src/Exercise@Etl/EtlTest.class.st
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,6 @@ EtlTest class >> exercise [
"Answer the configured exercise meta data for this exercise, an ExercismExercise"

^(self createExerciseAfter: ReverseStringTest)
isCore: false;
difficulty: 2;
topics: #('maps' 'iteration' 'transforming');
yourself
Expand Down
1 change: 0 additions & 1 deletion dev/src/Exercise@FlattenArray/FlattenArrayTest.class.st
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,6 @@ FlattenArrayTest class >> exercise [
"Answer the configured exercise meta data for this exercise, an ExercismExercise"

^ (self createExerciseAfter: ReverseStringTest)
isCore: false;
difficulty: 2;
topics: #('lists' 'iteration' 'recursion' 'transforming');
yourself
Expand Down
1 change: 0 additions & 1 deletion dev/src/Exercise@Forth/ForthTest.class.st
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,6 @@ ForthTest class >> exercise [
"Answer the configured exercise meta data for this exercise, an ExercismExercise"

^ (self createExerciseAfter: GradeSchoolTest)
isCore: true;
difficulty: 6;
topics: #('parsing' 'stacks');
yourself
Expand Down
1 change: 0 additions & 1 deletion dev/src/Exercise@GradeSchool/GradeSchoolTest.class.st
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,6 @@ GradeSchoolTest class >> exercise [


^(self createExerciseAfter: MatrixTest)
isCore: true;
difficulty: 4;
topics: #('sorting' 'filtering' 'lists' 'object_oriented_programming');
yourself
Expand Down
1 change: 0 additions & 1 deletion dev/src/Exercise@Grains/GrainsTest.class.st
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,6 @@ GrainsTest class >> exercise [
"Answer the configured exercise meta data for this exercise, an ExercismExercise"

^(self createExerciseAfter: IsogramTest)
isCore: true;
difficulty: 2;
topics: #('math' 'recursion');
yourself
Expand Down
1 change: 0 additions & 1 deletion dev/src/Exercise@Hamming/HammingTest.class.st
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,6 @@ Class {
{ #category : #config }
HammingTest class >> exercise [
^(self createExerciseAfter: ReverseStringTest)
isCore: false;
difficulty: 2;
topics: #('equality' 'loops' 'strings' 'exception_handling');
yourself
Expand Down
2 changes: 0 additions & 2 deletions dev/src/Exercise@HelloWorld/HelloWorldTest.class.st
Original file line number Diff line number Diff line change
Expand Up @@ -40,8 +40,6 @@ HelloWorldTest class >> exercise [
HelloWorld is a special case as it's the first exercise"

^(ExercismExercise for: self)
isCore: true;
isAutoApproved: true;
difficulty: 1;
topics: #('introduction' 'strings');
yourself
Expand Down
1 change: 0 additions & 1 deletion dev/src/Exercise@HighScores/HighScoresTest.class.st
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,6 @@ HighScoresTest class >> exercise [
"Answer the configured exercise meta data for this exercise, an ExercismExercise"

^(self createExerciseAfter: ReverseStringTest)
isCore: false;
difficulty: 2;
topics: #('lists' 'sorting' 'filtering');
yourself
Expand Down
1 change: 0 additions & 1 deletion dev/src/Exercise@IsbnVerifier/IsbnVerifierTest.class.st
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,6 @@ IsbnVerifierTest class >> exercise [
"Answer the configured exercise meta data for this exercise, an ExercismExercise"

^(self createExerciseAfter: LeapTest)
isCore: false;
difficulty: 3;
topics: #('characters' 'collections' 'validation');
yourself
Expand Down
1 change: 0 additions & 1 deletion dev/src/Exercise@Isogram/IsogramTest.class.st
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,6 @@ IsogramTest class >> exercise [
"Answer the configured exercise meta data for this exercise, an ExercismExercise"

^(self createExerciseAfter: ReverseStringTest)
isCore: true;
difficulty: 2;
topics: #('strings' 'iteration');
yourself
Expand Down
1 change: 0 additions & 1 deletion dev/src/Exercise@Leap/LeapTest.class.st
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,6 @@ LeapTest class >> exercise [
"Answer the configured exercise meta data for this exercise, an ExercismExercise"

^(self createExerciseAfter: TwoFerTest)
isCore: true;
difficulty: 1;
topics: #('math' 'conditionals' 'logic');
yourself
Expand Down
1 change: 0 additions & 1 deletion dev/src/Exercise@Luhn/LuhnTest.class.st
Original file line number Diff line number Diff line change
Expand Up @@ -85,7 +85,6 @@ LuhnTest class >> exercise [
"Answer the configured exercise meta data for this exercise, an ExercismExercise"

^(self createExerciseAfter: GrainsTest)
isCore: false;
difficulty: 4;
topics: #('strings' 'math' 'algorithms');
yourself
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,6 @@ MatchingBracketsTest class >> exercise [
"Answer the configured exercise meta data for this exercise, an ExercismExercise"

^(self createExerciseAfter: LeapTest)
isCore: false;
difficulty: 4;
topics: #('strings' 'parsing' 'stacks');
yourself
Expand Down
1 change: 0 additions & 1 deletion dev/src/Exercise@Matrix/MatrixTest.class.st
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,6 @@ MatrixTest class >> exercise [
"Answer the configured exercise meta data for this exercise, an ExercismExercise"

^(self createExerciseAfter: AllergiesTest)
isCore: true;
difficulty: 4;
topics: #('matrices' 'parsing');
yourself
Expand Down
1 change: 0 additions & 1 deletion dev/src/Exercise@Minesweeper/MinesweeperTest.class.st
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,6 @@ MinesweeperTest class >> exercise [
"Answer the configured exercise meta data for this exercise, an ExercismExercise"

^(self createExerciseAfter: AllergiesTest)
isCore: false;
difficulty: 5;
topics: #('parsing' 'iteration' 'transforming');
yourself
Expand Down
1 change: 0 additions & 1 deletion dev/src/Exercise@Pangram/PangramTest.class.st
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,6 @@ PangramTest class >> exercise [
"Answer the configured exercise meta data for this exercise, an ExercismExercise"

^(self createExerciseAfter: IsogramTest)
isCore: false;
difficulty: 2;
topics: #('strings' 'filtering');
yourself
Expand Down
1 change: 0 additions & 1 deletion dev/src/Exercise@Proverb/ProverbTest.class.st
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,6 @@ ProverbTest class >> exercise [
"Answer the configured exercise meta data for this exercise, an ExercismExercise"

^(self createExerciseAfter: ReverseStringTest)
isCore: false;
difficulty: 3;
topics: #('strings' 'iteration' );
yourself
Expand Down
1 change: 0 additions & 1 deletion dev/src/Exercise@Raindrops/RaindropsTest.class.st
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,6 @@ RaindropsTest class >> exercise [
"Answer the configured exercise meta data for this exercise, an ExercismExercise"

^(self createExerciseAfter: LeapTest)
isCore: false;
difficulty: 2;
topics: #('strings' 'conditionals' 'logic');
yourself
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,6 @@ ResistorColorDuoTest class >> exercise [


^(self createExerciseAfter: TwoFerTest)
isCore: false;
difficulty: 1;
topics: #('arrays' 'strings' 'math');
yourself
Expand Down
1 change: 0 additions & 1 deletion dev/src/Exercise@ReverseString/ReverseStringTest.class.st
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,6 @@ ReverseStringTest class >> exercise [
"Answer the configured exercise meta data for this exercise, an ExercismExercise"

^(self createExerciseAfter: LeapTest)
isCore: true;
difficulty: 1;
topics: #('strings' 'iteration');
yourself
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,6 @@ RobotSimulatorTest class >> exercise [
"Answer the configured exercise meta data for this exercise, an ExercismExercise"

^(self createExerciseAfter: GradeSchoolTest)
isCore: false;
difficulty: 4;
topics: #('iteration' 'tuples' 'object_oriented_programming');
yourself
Expand Down
1 change: 0 additions & 1 deletion dev/src/Exercise@RomanNumerals/RomanNumeralsTest.class.st
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,6 @@ RomanNumeralsTest class >> exercise [
"Answer the configured exercise meta data for this exercise, an ExercismExercise"

^(self createExerciseAfter: ReverseStringTest)
isCore: false;
difficulty: 3;
topics: #('iteration' 'maps' 'transforming');
yourself
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,6 @@ Class {
{ #category : #config }
SecretHandshakeTest class >> exercise [
^ (self createExerciseAfter: IsogramTest)
isCore: false;
difficulty: 2;
topics: #('arrays' 'bitwise operations');
yourself
Expand Down
1 change: 0 additions & 1 deletion dev/src/Exercise@Sieve/SieveTest.class.st
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,6 @@ SieveTest class >> exercise [
"Answer the configured exercise meta data for this exercise, an ExercismExercise"

^(self createExerciseAfter: GrainsTest)
isCore: false;
difficulty: 3;
topics: #('math' 'lists' 'loops');
yourself
Expand Down
2 changes: 0 additions & 2 deletions dev/src/Exercise@SimpleCipher/SimpleCipherTest.class.st
Original file line number Diff line number Diff line change
Expand Up @@ -85,8 +85,6 @@ Class {
SimpleCipherTest class >> exercise [

^(ExercismExercise for: self)
isCore: false;
isAutoApproved: true;
difficulty: 4;
topics: #('strings' 'string-methods' 'loops' 'numbers' 'lists' 'randomness');
yourself
Expand Down
1 change: 0 additions & 1 deletion dev/src/Exercise@SpaceAge/SpaceAgeTest.class.st
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,6 @@ SpaceAgeTest class >> exercise [
"Answer the configured exercise meta data for this exercise, an ExercismExercise"

^(self createExerciseAfter: TwoFerTest)
isCore: false;
difficulty: 1;
topics: #('dictionaries' 'math');
yourself
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,6 @@ SumOfMultiplesTest class >> exercise [
"Answer the configured exercise meta data for this exercise, an ExercismExercise"

^(self createExerciseAfter: LeapTest)
isCore: false;
difficulty: 3;
topics: #('iteration' 'filtering' 'math');
yourself
Expand Down
1 change: 0 additions & 1 deletion dev/src/Exercise@Tournament/TournamentTest.class.st
Original file line number Diff line number Diff line change
Expand Up @@ -87,7 +87,6 @@ TournamentTest class >> exercise [
"Answer the configured exercise meta data for this exercise, an ExercismExercise"

^(self createExerciseAfter: GradeSchoolTest)
isCore: false;
difficulty: 5;
topics: #('sorting' 'filtering' 'iteration' 'parsing' 'transforming' 'object_oriented_programming');
yourself
Expand Down
1 change: 0 additions & 1 deletion dev/src/Exercise@TwelveDays/TwelveDaysTest.class.st
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,6 @@ TwelveDaysTest class >> exercise [
"Answer the configured exercise meta data for this exercise, an ExercismExercise"

^(self createExerciseAfter: TwoFerTest)
isCore: false;
difficulty: 2;
topics: #('strings' 'iteration' 'text_formatting');
yourself
Expand Down
1 change: 0 additions & 1 deletion dev/src/Exercise@TwoFer/TwoFerTest.class.st
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,6 @@ TwoFerTest class >> exercise [
"Answer the configured exercise meta data for this exercise, an ExercismExercise"

^(self createExerciseAfter: HelloWorldTest)
isCore: true;
difficulty: 1;
topics: #('strings' 'text-formatting' 'refactoring');
yourself
Expand Down
1 change: 0 additions & 1 deletion dev/src/Exercise@WordCount/WordCountTest.class.st
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,6 @@ WordCountTest class >> exercise [
"Answer the configured exercise meta data for this exercise, an ExercismExercise"

^(self createExerciseAfter: AllergiesTest)
isCore: false;
difficulty: 3;
topics: #('strings' 'iteration' 'pattern_recognition');
yourself
Expand Down
Loading