diff --git a/.github/workflows/superlinter.yml b/.github/workflows/superlinter.yml index 96ce0cd..16c4a19 100644 --- a/.github/workflows/superlinter.yml +++ b/.github/workflows/superlinter.yml @@ -23,3 +23,4 @@ jobs: env: DEFAULT_BRANCH: main GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + \ No newline at end of file diff --git a/.vscode/settings.json b/.vscode/settings.json new file mode 100644 index 0000000..df27cec --- /dev/null +++ b/.vscode/settings.json @@ -0,0 +1,8 @@ +{ + "python.testing.pytestArgs": [ + "homework1" + ], + "python.testing.unittestEnabled": false, + "python.testing.nosetestsEnabled": false, + "python.testing.pytestEnabled": true +} \ No newline at end of file diff --git a/README.md b/README.md index 7b198eb..490f8ea 100644 --- a/README.md +++ b/README.md @@ -1,27 +1,7 @@ # Homework 1 - Week 3 -![Python package](https://github.com/vcu-chfauerbach/root_homework1/workflows/Python%20package/badge.svg) +![Python package](https://github.com/vcu-DBaptisteMitchell/root_homework1/workflows/Python%20package/badge.svg) -![Pylint](https://github.com/vcu-chfauerbach/root_homework1/workflows/Pylint/badge.svg) +![Pylint](https://github.com/vcu-DBaptisteMitchell/root_homework1/workflows/Pylint/badge.svg) -![Super-Linter](https://github.com/vcu-chfauerbach/root_homework1/workflows/Super-Linter/badge.svg) - -For your homework, fork this repository to your account. - -Updated the 'README.md' file to change the URLs for the github actions: - -https://github.com/vcu-chfauerbach/root_homework1/workflows/Pylint/badge.svg - -should become - -https://github.com/YOUR_GITHUB_ACCOUNT/root_homework1/workflows/Pylint/badge.svg - -Edit the file ./homework1/hw1.py to make the three github actions pass. - -When they pass, and you see the updated badges in your repository, send me a link to the repository, like: - -https://github.com/vcu-chfauerbach/root_homework1 - -but - -https://github.com/YOUR_GITHUB_ACCOUNT/root_homework1 +![Super-Linter](https://github.com/vcu-DBaptisteMitchell/root_homework1/workflows/Super-Linter/badge.svg) diff --git a/homework1/hw1.py b/homework1/hw1.py index e642eac..4a2cad3 100644 --- a/homework1/hw1.py +++ b/homework1/hw1.py @@ -4,14 +4,14 @@ def return_number_3(): """ This function should return an integer with the value of 3""" - return_value = None + return_value = 3 return return_value def return_string_vcu(): """ This function should return a string with the lowercase value of vcu""" - return_value = None + return_value = "vcu" return return_value @@ -19,7 +19,7 @@ def return_lowercased_string(input_string): """You have a variable called input_string that is of type string. Return it but the lowercase version of it.""" - return_value = input_string + return_value = input_string.lower() return return_value @@ -27,12 +27,12 @@ def return_without_starting_ending_whitespace(input_string): """You have a variable called input_string that is of type string. Return it but with the surrounding (left and right) whitespace stripped.""" - return_value = input_string + return_value = input_string.strip() return return_value def return_addition(first_number, second_number): """ Return the two numbers added together. """ - return_value = None + return_value = first_number + second_number return return_value