17.5 / 20
Koutensky - (-0,5) teoria - chyba. - (-0,5) navrh - chyba, resp. jedna veta. co je skoda, pretoze toto je jeden z mala projektov kde je nejaky rozumny navrh o ktorom by sa dalo pisat. - (-0,5) testovanie - koncepcne dobre, hodilo by sa ale popisat jednotlive situacie ktore boli testovane priamo v hlavnom texte. - kod - rozumny oop navrh, chvalim pouzitie abstraktnej baze.
This README is the main documentation for this project.
ipkcpc -h <host> -p <port> -m <mode>
gcc
make
For testing
python3
make
Builds the project and createsipkcpc
binary in project rootmake run_tcp
Builds project and runs client in TCP mode with default (examples) argumentsmake run_udp
Builds project and runs client in UDP mode with default (example) argumentsmake test
Runs tests. NOTE: Both TCP and UDP server has to be running.make zip
Creates final ZIP file for assignment submissionmake clean
Cleans temporary files (e.g object files)
These are the notable files and folders.
/examples
Example inputsipkcpc.cc
Entry pointargs.cc
,args.hpp
Argument parsing moduleclient.cc
,client.hpp
Abstract base class, factory for clientstcp-client.cc
,tcp-client.hpp
TCP client implementationudp-client.cc
,udp-client.hpp
UDP client implementationtest.py
Tests
The application is written in C++20. Client is abstract class and factory for specific (currently TCP and UDP) implementations. Arguments are parsed in their own module. Project aims to be simple and extensible.
Testing was done with custom tests written in Python 3 with unittest library.
It tests tcp, udp comunication and argument parsing. Tests live in test.py
, they have it's own help, which can be viewed with python3 test.py -h
.
Some edge-cases hard to tests automatically were tested manually, this could be
improved in the future.
The application was tested as a whole. It was also confirmed that it compiles and runs on the reference VM. Tests require two servers running (one in TCP and other in UDP mode) and can be run against reference ipkcpd implementation or any other compatible implementation.
Testing proof is located in test.log
file.
Client automatically sends BYE message if user doesn't do it. This means, that if you supply file without BYE message at the end, connection will still properly terminate.
License in located in LICENSE file.
- Changelog format - https://keepachangelog.com/cs/1.0.0/
- General project instructions - https://git.fit.vutbr.cz/NESFIT/IPK-Projekty/src/branch/master
- Project instructions https://git.fit.vutbr.cz/NESFIT/IPK-Projekty/src/branch/master/Project%201
- Protocol specification https://git.fit.vutbr.cz/NESFIT/IPK-Projekty/src/branch/master/Project%201/Protocol.md
- C++ reference https://en.cppreference.com/w/