This project consists in practicing web scraping on the Trybe's blog.
In this project, I was able to:
- Apply web scraping technics;
- Extract data from HTML content;
- Maintain the extracted data on a NoSQL database.
Python | Pytest | Requests | Parsel | Pymongo |
---|---|---|---|---|
|
|
|
|
|
- Clone the repository and enter it
git clone [email protected]:ImVictorM/Tech-News.git && cd Tech-News
- Get the containers running
docker-compose up -d
- Enter the app container
docker exec -it tech_news bash
- Install the main package
pip install .
- Init the app
tech-news-analyzer
You must have mongodb installed
- Create the virtual environment
python3 -m venv .venv && source .venv/bin/activate
- Install the dependencies
python3 -m pip install -r dev-requirements.txt
- Install the main package
pip install .
- Init the app
tech-news-analyzer
To run all tests:
python3 -m pytest
Running only one test file:
python3 -m pytest {test_file_path}.py