-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
29f6acb
commit fd630f1
Showing
4 changed files
with
120 additions
and
0 deletions.
There are no files selected for viewing
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,54 @@ | ||
# Help | ||
|
||
## Running the tests | ||
|
||
For running the tests provided, you will need the Minitest gem. Open a | ||
terminal window and run the following command to install minitest: | ||
|
||
``` | ||
gem install minitest | ||
``` | ||
|
||
|
||
Run the tests from the exercise directory using the following command: | ||
|
||
``` | ||
ruby <snake-case-exercise>_test.rb | ||
``` | ||
|
||
Please replace `<snake-case-exercise>` with your exercise name in snake_case. | ||
|
||
## Color output | ||
|
||
You can `require 'minitest/pride'` or run the following command to get colored output: | ||
|
||
``` | ||
ruby -r minitest/pride <snake-case-exercise>_test.rb | ||
``` | ||
|
||
## Submitting your solution | ||
|
||
You can submit your solution using the `exercism submit hello_world.rb` command. | ||
This command will upload your solution to the Exercism website and print the solution page's URL. | ||
|
||
It's possible to submit an incomplete solution which allows you to: | ||
|
||
- See how others have completed the exercise | ||
- Request help from a mentor | ||
|
||
## Need to get help? | ||
|
||
If you'd like help solving the exercise, check the following pages: | ||
|
||
- The [Ruby track's documentation](https://exercism.org/docs/tracks/ruby) | ||
- The [Ruby track's programming category on the forum](https://forum.exercism.org/c/programming/ruby) | ||
- [Exercism's programming category on the forum](https://forum.exercism.org/c/programming/5) | ||
- The [Frequently Asked Questions](https://exercism.org/docs/using/faqs) | ||
|
||
Should those resources not suffice, you could submit your (incomplete) solution to request mentoring. | ||
|
||
To get help if you're having trouble, you can use one of the following resources: | ||
|
||
- [Ruby Documentation](http://ruby-doc.org/) | ||
- [StackOverflow](http://stackoverflow.com/questions/tagged/ruby) | ||
- [/r/ruby](https://www.reddit.com/r/ruby) is the Ruby subreddit. |
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,52 @@ | ||
# Hello World | ||
|
||
Welcome to Hello World on Exercism's Ruby Track. | ||
If you need help running the tests or submitting your code, check out `HELP.md`. | ||
|
||
## Instructions | ||
|
||
The classical introductory exercise. | ||
Just say "Hello, World!". | ||
|
||
["Hello, World!"][hello-world] is the traditional first program for beginning programming in a new language or environment. | ||
|
||
The objectives are simple: | ||
|
||
- Modify the provided code so that it produces the string "Hello, World!". | ||
- Run the test suite and make sure that it succeeds. | ||
- Submit your solution and check it at the website. | ||
|
||
If everything goes well, you will be ready to fetch your first real exercise. | ||
|
||
[hello-world]: https://en.wikipedia.org/wiki/%22Hello,_world!%22_program | ||
|
||
## Source | ||
|
||
### Created by | ||
|
||
- @ramonh | ||
|
||
### Contributed to by | ||
|
||
- @abartov | ||
- @bgrabow | ||
- @budmc29 | ||
- @gilmatic | ||
- @hilary | ||
- @iHiD | ||
- @Insti | ||
- @jpotts244 | ||
- @Kosmas | ||
- @kotp | ||
- @kytrinyx | ||
- @mike-hewitson | ||
- @NeimadTL | ||
- @sivabudh | ||
- @skeskali | ||
- @thejoycekung | ||
- @trayo | ||
- @tryantwit | ||
|
||
### Based on | ||
|
||
This is an exercise to introduce users to using Exercism - https://en.wikipedia.org/wiki/%22Hello,_world!%22_program |
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
class HelloWorld | ||
def self.hello | ||
"Hello, World!" | ||
end | ||
end |
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
require 'minitest/autorun' | ||
require_relative 'hello_world' | ||
|
||
class HelloWorldTest < Minitest::Test | ||
def test_say_hi | ||
# skip | ||
assert_equal "Hello, World!", HelloWorld.hello | ||
end | ||
end |