Skip to content

bhavya9107/Swiss-system-tournament

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

11 Commits
 
 
 
 
 
 
 
 

Repository files navigation

tournament-results

Project Specification

Develop a database schema to store details of a games matches between players.
Then write a Python module to rank the players and pair them up in matches in a tournament.

Files

tournament.py

Contains the implementation for the Swiss tournament

tournament.sql

Contains the SQL queries to create the database, tables and views

tournament_test.py

Contains the test cases for tournament.py

Instructions

  1. Start Vagrant
  2. Open Terminal or cmd and browse to the vagrant folder
  3. Type vagrant up
  4. SSH in to the vagrant VM
  5. In the same terminal type vagrant ssh
  6. Change to the correct folder
  7. Type cd /vagrant/tournament
  8. Open PSQL and run the tournament.sql
  9. type psql
  10. type psql -f tournament.sql in terminal to import the tournament database
  11. type \q to quit out of PSQL
  12. Run the tests
  13. In the terminal type python tournament_test.py

Expected Outcome

Success! All tests pass!
vagrant@vagrant-ubuntu-trusty-32:/vagrant/tournament$ python tournament_test.py

  1. Old matches can be deleted.
  2. Player records can be deleted.
  3. After deleting, countPlayers() returns zero.
  4. After registering a player, countPlayers() returns 1.
  5. Players can be registered and deleted.
  6. Newly registered players appear in the standings with no matches.
  7. After a match, players have updated standings.
  8. After one match, players with one win are paired.
    Success! All tests pass!

About

tournament manager

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages