A spotify based musical quiz application.
This project was created in Mars, 2016. The purpose of the application is to simplify the task to create and distribute music quizes.
A presentation made at the end of this project, 2016-03-14.
All members are students of Chalmers University of Technology, Software Engineering. This project was created for the course "DAT076 - Web Applications".
Name | SSN | |
---|---|---|
Erik Nordmark | 870907 | erinord@student.chalmers.se |
Joakim Berntsson | 940524 | joabern@student.chalmers.se |
Simon Takman | 930321 | takman@student.chalmers.se |
Tim Kerschbaumer | 931022 | ktim@student.chalmers.se |
Git inspector was quite troublesome for us during this project. If someone auto indented or made a special merge, several hundred rows could be transfered from one person to another. This lead to some members being below the required limit for SLOCs.
The application is a spotify based music quiz, which lets the user invite friends, choose a playlist and start a quiz based on that playlist. The creator will have control of the music but no other special permissions is given to the creator.
The application requires a spotify account, network connection and a modern web browser.
The use cases includes name, goal, actors, precondition, main flow, alternative flow and postcondition.
The application is built with AngularJS as the frontend application and Java EE as the backend solution.
The application is built with the service based approach pattern.
Charlie/src/main/java/core/Player.java
Charlie/src/main/java/core/Question.java
Charlie/src/main/java/core/Quiz.java
Charlie/src/main/java/core/User.java
Charlie/src/main/java/core/UserIdentity.java
Charlie/src/main/java/core/UserSession.java
Charlie/src/main/java/core/UserIdentity.java
Charlie/src/main/java/core/User.java
Charlie/src/main/java/core/SpotifyService.java
Charlie/src/main/java/web/WebsocketServer.java
Charlie/src/main/webapp/app/js/controllers.js
Charlie/src/main/webapp/index.html
Charlie/src/main/webapp/app/partials/create.html
Charlie/src/main/webapp/app/partials/profile.html
Charlie/src/main/webapp/app/partials/home.html
Charlie/src/main/webapp/app/partials/lobby.html
Charlie/src/main/webapp/app/partials/question.html
Charlie/src/main/webapp/app/partials/scoreboard.html
Backend
- Java Enterprise Edition
- Michaelthelin Spotify API
- Google Gson
- Apache Derby
- JUnit
- Arquillian
Frontend
- Jasmine
- Angular
- Angular Material Design
- Bootstrap
- JQuery
This section explains how to setup and run the project and its tests.
To run this project follow the instructions below.
git clone https://github.com/jcberntsson/Charlie.git
Then open the project in Netbeans and add a database called "db" in the services tab.
You must also create a file for connecting with the Spotify API.
Charlie/src/main/java/core/SpotifyCredentials.java
The credentials can be obtained from Spotifys website. The structure of the file should be the following:
package core;
public class SpotifyCredentials {
public static final String clientID = "...";
public static final String clientSecret = "...";
public static final String redirectURI = "http://localhost:8080/Charlie/callback.html";
}
To run the jasmine tests do the following.
git clone https://github.com/jcberntsson/Charlie.git
cd Charlie
npm install
karma start
To run the JUnit for this project do the following.
git clone https://github.com/jcberntsson/Charlie.git
Please read JUNIT_README for further information. Open in Netbeans and run test files:
Charlie/src/main/test/core/PlayerTest.java
Charlie/src/main/test/core/QuestionTest.java
Charlie/src/main/test/core/QuizTest.java
Charlie/src/main/test/core/SpotifyServiceTest.java
To run the Arquillian test for this project do the following.
git clone https://github.com/jcberntsson/Charlie.git
Open in Netbeans and run the following file:
Charlie/src/test/java/TestUserPersistence.java