Story points | 3 |
Tags | tdd error-checking |
Hard Prerequisites | |
IMPORTANT: Please review these prerequisites, they include important information that will help you with this content. | |
|
Please note that this is a unit testing project. Make sure you demonstrate a solid understanding of unit testing and test your code using the required framework.
Your directory structure should look like this.
├── spec
| ├── support
| | └── jasmine.json
| └── ???
├── src
| └── password_checker.js
└── package.json
Note: It is important that you export all the functions we are asking you to write. Use the following named export syntax:
module.exports = { firstFunctionName, secondFunctionName }
Your project is expected to be completed using pytest
. You are expected to follow industry best practices in all things. This means that you need to have a directory structure that is in good shape. Please name your files and folders like this:
├── password_checker the package under test
│ └── password_checker.py
├── requirements.txt installation requirements
├── setup.py installation script for the package under test
└── tests all package tests go in this directory
├── ???
Please take a look at this topic to see an explanation of the required directory structure. TOPIC: Automated Testing in Python
Please make use of Gradle from the command line to set up your project. You can learn more about Gradle here:
[TODO] TOPIC: African Coding Network SyllabusWhen you use gradle to create your project, give your project the following name: password_checker
The code you push to git should have the following structure:
├── gradle
│ └── wrapper
│ ├── gradle-wrapper.jar
│ └── gradle-wrapper.properties
├── gradlew
├── gradlew.bat
├── settings.gradle
└── app
├── build.gradle
└── src
├── main
| └── java
| └── password_checker
| └── PasswordChecker.java <-------- names are important
└── test
└── java
└── password_checker
└── ???.java <-------- names are important
Please name your project password_checker
and put your work in the password_checker
package.
Create a function called password strength
. This function should take one parameter (the password) and it should return the strength of the password.
Here are criteria that are used for judging the strength of a password:
{ % & * " '
etc.This is how the strength of the password is calculated
Java learners: We should not need to instantiate your class in order to call this function.
P@ssw 12
, User1@
.