Skip to content

Commit

Permalink
Edits upon Review
Browse files Browse the repository at this point in the history
  • Loading branch information
Kareiman committed Jan 11, 2025
1 parent 6773f0d commit a804d52
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 8 deletions.
16 changes: 8 additions & 8 deletions solutions/convert_to_capital.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
# -*- coding: utf-8 -*-

"""
A module that converts letters to upper case
A module that converts letters to uppercase
Created on 31 12 2024
Expand All @@ -13,15 +13,15 @@
def convert_to_capital(user_text: str) -> str:
"""Asks the user to enter a text and returns the text in capital
parameters:
user_text = in str
returns:
user_text in capital letters
Parameters:
user_text (str): The user input text to be converted to uppercase.
Returns:
(str) : user_text in capital letters
raises:
AssertionError: if input is empty
Raises:
AssertionError: If the input is empty or contains only spaces.
examples:
Examples:
>>> convert_to_capital('hello')
'HELLO'
>>> convert_to_capital('HelLo')
Expand Down
5 changes: 5 additions & 0 deletions solutions/tests/test_convert_to_capital.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,11 @@
"""
A module to test convert_to_capital function
Test categories:
- Standard cases: Regular text with different length
- Edge cases: Mix of different data types
- Defensive tests: Empty input
Created on 03 01 2025
@author: Kareiman Altayeb
Expand Down

0 comments on commit a804d52

Please sign in to comment.