Giter VIP home page Giter VIP logo

udacity-project2's Introduction

#FSND Project 2 - Tournament Results Originally forked from fullstack-nanodegree-vm.

This project demonstrates creating and updating a data model within a relational database as a persistence layer as well as how to push some logic down to the RDBMS for simplifying app-level logic.

Requirements

The project was built using the following software and their versions.

Tip for Initializing the Vagrant Instance

There have been some known issues with Vagrant and the versions of curl on some operating systems. Using a preview build of MacOS X 10.10.4 required pulling down the box image first and adding it to the local Vagrant environment. You can try pulling the box down manually via a browser or curl and then adding the box before running vagrant up per the Usage instructions.

curl http://cloud-images.ubuntu.com/vagrant/trusty/current/trusty-server-cloudimg-i386-vagrant-disk1.box > ubuntu_trusty32.box

vagrant add ubuntu_trusty32.box ubuntu/trusty32

Usage

Bring the Vagrant managed VM online

vagrant up

Connect to the system via SSH

vagrant ssh

Change to the directory within the VM that's mapped to our project files.

cd /vagrant

First, bootstrap the Tournament PostgreSQL database using the provided SQL script.

psql -f tournament.sql

Run the test Python script that manipulates the state of the tournament within the database and validates Swiss Pairings.

python tournament_test.sql

If everything works, you should see valid output resembling:

1. Old matches can be deleted.
2. Player records can be deleted.
3. After deleting, countPlayers() returns zero.
Adding player "Chandra Nalaar"
4. After registering a player, countPlayers() returns 1.
Adding player "Markov Chaney"
Adding player "Joe Malik"
Adding player "Mao Tsu-hsi"
Adding player "Atlanta Hope"
5. Players can be registered and deleted.
Adding player "Melpomene Murray"
Adding player "Randy Schwartz"
6. Newly registered players appear in the standings with no matches.
Adding player "Bruno Walton"
Adding player "Boots O'Neal"
Adding player "Cathy Burton"
Adding player "Diane Grant"
7. After a match, players have updated standings.
Adding player "Twilight Sparkle"
Adding player "Fluttershy"
Adding player "Applejack"
Adding player "Pinkie Pie"
8. After one match, players with one win are paired.
Success!  All tests pass!

References

In identifying the approach for creating the Standings and Swiss Pairings, I consulted a few sources.

udacity-project2's People

Contributors

voutilad avatar lobrown avatar karlud avatar

Watchers

James Cloos avatar  avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.