Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
86 commits
Select commit Hold shift + click to select a range
f346945
Ignore IntelliJ files.
choshun Aug 28, 2021
a150b56
Add linting at pre-commit.
choshun Aug 28, 2021
5db2067
add cypress smoke test
choshun Aug 28, 2021
878be10
ignore cypress files
choshun Aug 28, 2021
00001a7
git hook for push smoke test
choshun Aug 28, 2021
8b2bda7
Ignore only cypress results
choshun Aug 28, 2021
01ee913
Updated deps after setting local node version.
choshun Sep 12, 2021
5696443
Ignore cypress example.
choshun Sep 12, 2021
2a6faa4
Update README.
choshun Sep 12, 2021
5c8c6c8
Add create round smoke test.
choshun Sep 12, 2021
bfa4b6d
Small README update.
choshun Sep 12, 2021
550ceac
Update README.md
batchku Sep 12, 2021
a773c7f
Update README.md
batchku Sep 12, 2021
de523b8
Update README.md
batchku Sep 13, 2021
d6ce317
Update README.md
batchku Sep 13, 2021
ef90527
Update README.md
batchku Sep 13, 2021
4551ede
Feature/166 ci cypress tests inclusion (#178)
muganwas Oct 1, 2021
fd71e27
changed from cypress run to node_modules/.bin/cypress run (#181)
muganwas Oct 1, 2021
2af80a5
Bugs/180 cypress run action fails (#182)
muganwas Oct 1, 2021
859fb62
Add eslint for cypress. We also _want_ package.lock in git, it's what…
choshun Oct 2, 2021
163eedb
Add logged in test, also make sure you're logged out at start of test.
choshun Oct 2, 2021
e552449
Guess we have to ignore this for githubs clean build?
choshun Oct 2, 2021
818b953
Github hates package-lock I guess
choshun Oct 2, 2021
98c6f56
No clue, see what happens.
choshun Oct 2, 2021
c06cb4f
Seeing if a clean yarn build helps.
choshun Oct 2, 2021
4f9470f
Revert "Seeing if a clean yarn build helps."
choshun Oct 5, 2021
388c300
improved on test to check for a few conditions (#189)
muganwas Oct 6, 2021
fe91581
Update how work is added (#193)
choshun Oct 13, 2021
6ec715c
Bugs/86 time offset sliders steps on wrong layer (#190)
muganwas Oct 13, 2021
ea18ee4
positioned lowpass and highpass at the bottom of the array. (#192)
muganwas Oct 20, 2021
8ebcd3c
Feature/166 deploy using GitHub actions (#196)
muganwas Oct 21, 2021
2fe897c
Feature/91 mute greysout ring (#199)
muganwas Oct 26, 2021
805ef84
removed layer type selector (#200)
muganwas Oct 26, 2021
c9f2029
removed metal group from LayerSettings (#201)
muganwas Oct 26, 2021
16236c7
removed record button and widened dropzone (#202)
muganwas Oct 26, 2021
68c0e96
dimmed other users layers (#203)
muganwas Oct 26, 2021
223d9a0
only update step after change is finalized (#204)
muganwas Oct 26, 2021
57d7fd8
Feature/194 randomise instrument sounds (#206)
muganwas Oct 26, 2021
8f37eb1
disabled mapping space bar to play toggle (#207)
muganwas Oct 26, 2021
97fb5b8
Feature/125 add pingpong delay fx (#208)
muganwas Oct 26, 2021
4eb3a71
latest round always on top (#209)
muganwas Oct 26, 2021
05b98fd
saved fx state is reflected on load (#210)
muganwas Oct 26, 2021
0dcabed
Feature/217 disable synced play pause (#222)
muganwas Nov 19, 2021
203a94c
double click limited to only layer graphic (#231)
muganwas Dec 1, 2021
7f2280b
remove preventDefault (#240)
muganwas Dec 2, 2021
42106bd
Feature/212 move layer inspector to bottom center (#219)
muganwas Dec 6, 2021
5f98cc4
Feature/230 new moving layer inspector from left panel to bottom midd…
muganwas Jan 7, 2022
37e7641
Bug/244 layer inspector mobile no space btwn buttons (#248)
muganwas Jan 7, 2022
00b2698
fixed height and icons positioning issues (#249)
muganwas Jan 7, 2022
c286885
removed share word, made share icon round and conditional display of …
muganwas Jan 7, 2022
1cc1121
improved dimensions (#251)
muganwas Jan 10, 2022
1721238
Feature/242 new effects side panel (#243)
muganwas Jan 10, 2022
9224915
Update PlayRoute.js (#252)
muganwas Jan 10, 2022
644a844
Bug/122 drag to add remove notes not working properly (#211)
muganwas Jan 10, 2022
d0d755d
Bug/159 participants in a collab cannot hear steps created by others …
muganwas Jan 12, 2022
8bd0ee4
center, rounded corders to 8px (#256)
muganwas Jan 14, 2022
ee22487
fixed layer ordering (#257)
muganwas Jan 14, 2022
96636ea
await createRound (#262)
muganwas Jan 20, 2022
3ca3be1
update state os selectedLayer change (#258)
muganwas Jan 20, 2022
a2f9c87
Feature/213 moving pattern presets sequencer to center (#264)
muganwas Apr 7, 2022
32cc47e
new project modal
muganwas Mar 21, 2022
729aebf
Choose file & upload UI
muganwas Mar 22, 2022
fd3e4a4
Update CreateRoundModal.js
muganwas Mar 22, 2022
e9abf7f
Update CreateRoundModal.js
muganwas Mar 22, 2022
d65bbf0
File selection
muganwas Mar 24, 2022
a9362e9
Playback and unsupported alert
muganwas Mar 25, 2022
3cfc12c
upload sounds to firebase
muganwas Mar 25, 2022
8b1025d
upload sound and create new samples
muganwas Mar 28, 2022
1a4a9dc
created round from custom instruments/sound
muganwas Mar 29, 2022
a497cd3
Update PlayRoute.js
muganwas Mar 29, 2022
e4d541c
upload sound and store sampleId within layer information
muganwas Mar 31, 2022
b3e1611
Update CreateRoundModal.js
muganwas Apr 1, 2022
967ed45
Update CreateRoundModal.js
muganwas Apr 1, 2022
34ba6b0
Update CreateRoundModal.js
muganwas Apr 1, 2022
15a5c42
show instrument name
muganwas Apr 7, 2022
b511676
Fixed custom sounds list issue
muganwas Apr 7, 2022
d86e285
Poly Synthesis and bug fixes
muganwas Apr 8, 2022
6a7e1fd
Update Custom.js
muganwas Apr 11, 2022
9657748
default selected instrument and sound fix
muganwas Apr 12, 2022
e6e3601
rename createRoundModal
muganwas Apr 12, 2022
452bfe1
upload custom instrument dialog
muganwas Apr 12, 2022
1fd487b
Update CustomInstrumentDialog.js
muganwas Apr 13, 2022
9d75580
set instrument name
muganwas Apr 13, 2022
8b901c0
upload and add instrument
muganwas Apr 14, 2022
1269534
add instrument to round
muganwas Apr 19, 2022
998cd02
changing layer instrument to custom
muganwas Apr 20, 2022
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 3 additions & 2 deletions .firebaserc
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
{
"projects": {
"roundaround": "roundaround"
"roundaround": "roundaround",
"default": "roundaround"
},
"targets": {
"roundaround": {
Expand All @@ -17,4 +18,4 @@
}
}
}
}
}
22 changes: 22 additions & 0 deletions .github/workflows/firebase-hosting-merge.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
# This file was auto-generated by the Firebase CLI
# https://github.com/firebase/firebase-tools

name: Deploy to Firebase Hosting on merge
'on':
push:
branches:
- master
jobs:
build_and_deploy:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- run: |
yarn install
yarn build
- uses: FirebaseExtended/action-hosting-deploy@v0
with:
repoToken: '${{ secrets.GITHUB_TOKEN }}'
firebaseServiceAccount: '${{ secrets.FIREBASE_SERVICE_ACCOUNT_ROUNDAROUND }}'
channelId: live
projectId: roundaround
19 changes: 19 additions & 0 deletions .github/workflows/firebase-hosting-pull-request.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
# This file was auto-generated by the Firebase CLI
# https://github.com/firebase/firebase-tools

name: Deploy to Firebase Hosting on PR
'on': pull_request
jobs:
build_and_preview:
if: '${{ github.event.pull_request.head.repo.full_name == github.repository }}'
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- run: |
yarn install
yarn build
- uses: FirebaseExtended/action-hosting-deploy@v0
with:
repoToken: '${{ secrets.GITHUB_TOKEN }}'
firebaseServiceAccount: '${{ secrets.FIREBASE_SERVICE_ACCOUNT_ROUNDAROUND }}'
projectId: roundaround
26 changes: 26 additions & 0 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
name: End-to-end tests
on: [push, pull_request]
jobs:
cypress-eslint-run:
runs-on: ubuntu-20.04
# env:
# CYPRESS_BASE_URL: https://roundaround-stage.web.app/
steps:
- name: Checkout
uses: actions/checkout@v2
# Install NPM dependencies, cache them correctlyand run all Cypress tests
- name: set master url
if: github.ref == 'refs/heads/master'
run: CYPRESS_BASE_URL=http://rounds.studio
- name: set stage url
if: github.ref == 'refs/heads/stage'
run: CYPRESS_BASE_URL=https://roundaround-stage.web.app/
- name: set dev url
if: github.ref != 'refs/heads/stage' && github.ref != 'refs/heads/master'
run: CYPRESS_BASE_URL=https://roundaround-dev.web.app/
- name: Cypress run
uses: cypress-io/github-action@v2
#uses: actions/download-artifact@v2
# Run Eslint checks
- name: Eslint run
run: ./node_modules/.bin/eslint --ext js,jsx src
11 changes: 10 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -17,4 +17,13 @@ ref

functions/node_modules

.eslintcache
.eslintcache

# Ignore IntelliJ generated files
.idea

# Cypress test results
cypress/screenshots
cypress/videos
cypress/results
cypress/fixtures/example.json
2 changes: 2 additions & 0 deletions .husky/pre-commit
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
#!/bin/sh
./node_modules/.bin/eslint --ext js,jsx src
81 changes: 72 additions & 9 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,23 +17,86 @@ Reference:
- Simple radial multi-layer simple sequencer: https://tylerbisson.com/Groove-Pizzeria/
- Another simple implementation: https://github.com/NYUMusEdLab/Accessible-Groove-Pizza

## Musical Concepts
![Step Sequencers: Traditional (Linear) and Radial Metaphors](/docs/images/RoundAround_StepSequencers.jpeg)

## Data Concepts
![Key Data Concepts for RoundAround](/docs/images/RoundAround_Concepts.jpeg)
# Development

## Set Node Version
Please use node v14.17.6 - the latest stable version of node, [nvm](https://tecadmin.net/install-nvm-macos-with-homebrew/) is an easy way to do this

## Local Development
- `yarn`
- `yarn start`
On OX, install Homebrew if you don't have it:
```
ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)"
```

Install and select said version of Node:
```
nvm install 14.17.6
nvm use v14.17.6
node -v // should be 14.17.6
```

### (Optional) Clean Install Modules
```
yarn install --frozen-lockfile`
```

## Local development
- Go to your local branch
- `yarn` - To install packages that may have changed since your last branch
- `yarn build` - To do a clean build of js
- `yarn start` - To start the local server
- navigate to [http://localhost:3000](http://localhost:3000)

## Dev workflow
We use [git flow](https://www.atlassian.com/git/tutorials/comparing-workflows/gitflow-workflow#:~:text=The%20overall%20flow%20of%20Gitflow,branch%20is%20created%20from%20main&text=When%20a%20feature%20is%20complete%20it%20is%20merged%20into%20the,branch%20is%20created%20from%20main)

### Summary
- Make sure master is always production ready
- Create feature/bug branches for every issue; put issue ID brance name, e.g. "bug/163-fix-step-count" for [Issue #163](https://github.com/irllabs/roundaround/issues/163)
- Merge `feature` branches into `stage` as soon as it's ready to minimize merge conflicts and lack of transparency in what the code will look like once it's deployed to `prod`.

### Branchines
- `master` - always runs, is deployed to `prod` (http://rounds.studio and http:/rounds.irl.studio)
- `stage` - always runs, features are merged to it; is deployed to `stage` (http://roundaround-stage.web.app) when testing integration of features
- `feature/<GitHub-issue-number>-<Feature-Description>` - one for each issue labeled as `enhancement` in github, deployed to `dev` (http://roundaround-dev.web.app) when testing a feature is useful
- `bug//<GitHub-issue-number>-<Bug-Description>` - one for each issue labeled as `bug`, deployed to `dev` (http://roundaround-dev.web.app) when testing a bug is useful

### How is new work added?
- checkout `stage` and create a new feature/bug branch
- If you want feedback deploy that branch out to `roundaround-dev.web.app`. It's fine if its buggy at the point of feedback
- When you are confident the new feature is completed make a PR and do a [full regression test](https://docs.google.com/spreadsheets/d/1fn3mY7sy1YfqoeCXUstYxEqKOidWj6KFN_negDrXKeQ/edit#gid=116044031).

Deploy to `roundaround-dev.web.app`. Ask product to test the added functionality. They will _not_ do a regression
- If the tests pass, the PR is approved, and we're happy with the added functionality, merge that branch to stage.

Deploy to `https://roundaround-stage.web.app/`
- When we want to merge into master, deploy that (or those) features to the stage server if they aren't already, and _everyone_ does a full regression before we make a PR for stage to master
- If the tests pass we merge to master.

Deploy to `roundaround-dev.web.app`

Summary - we never make a branch off master, only stage, and we only ever merge into master after stage is fully regression tested. We try to get feature branches into stage as soon as possible, so we can be confident we're always moving forward building on tested and verified work.



## Testing
- As of now there's a git hook to make sure any code committed is linted and doesn't add malformed js
- As of now there's a smoke test that runs locally to make sure the site still loads when pushing

If the smoke test fails you can debug it with:
`yarn run cypress:open`

make sure the site is running locally.

## Deploy frontend
- `yarn build`
- `firebase deploy --only hosting:production`
Should update `https://roundaround.web.app/`, this should always be master
- `firebase deploy --only hosting:stage`

Should update `https://roundaround-stage.web.app/`, this should always be develop and be in a stablish state
- `firebase deploy --only hosting:dev`
Should update `https://roundaround-dev.web.app/`, this can be any branch off develop, it's fine if it's buggy

## Deploy functions (generates Jitsi tokens)
- Make sure you have the jaasauth.pk private key file in the root of the functions folder (not kept in git)
- `firebase deploy --only functions`
- `firebase deploy --only functions`
12 changes: 12 additions & 0 deletions cypress.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
{

"chromeWebSecurity": false,
"baseUrl": "https://roundaround-dev.web.app/",
"defaultCommandTimeout": 20000,
"viewportWidth": 1300,
"reporter": "junit",
"reporterOptions": {
"mochaFile": "cypress/results/cypress-report-[hash].xml"
},
"projectId": "miag47"
}
5 changes: 5 additions & 0 deletions cypress/.eslintrc.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
{
"extends": [
"plugin:cypress/recommended"
]
}
60 changes: 60 additions & 0 deletions cypress/integration/smoke/see-a-round.spec.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,60 @@
const crypto = require('crypto');

describe("Can see a round", () => {
let hash;

beforeEach(() => {
hash = crypto.randomBytes(3).toString('hex');
cy.clearLocalStorage();
cy.clearCookies();
});

it("As a guest", () => {
cy.logout();

cy.get("[data-test=button-get-started]").click();
cy.get("[data-test=app]").should("be.visible");

cy.get("[data-test=button-guest]").click();
cy.get("[data-test=app]").should("be.visible");

cy.get("[data-test=input-name]").type(`test-${hash}`);
cy.get("[data-test=button-name]").click();

cy.get("[data-test=app]").should("be.visible");
cy.get(".round").should("be.visible");

cy.logout();

cy.get("[data-test=app]").should("be.visible");
});

it("As a registered user", () => {
cy.login();

cy.get('html').then(($html) => {
if ($html.find("[data-test=list-item-round]").length) {
cy.get("[data-test=list-item-round]").first().click();
cy.get("[data-test=app]").should("be.visible");
cy.get(".round").should("be.visible");
cy.logout();
cy.get("[data-test=app]").should("be.visible");
} else if ($html.find("[data-test=button-new-round]").length) {
cy.get("[data-test=button-new-round]").click();
cy.get("[data-test=app]").should("be.visible");
cy.get(".round").should("be.visible");
cy.logout();
cy.get("[data-test=app]").should("be.visible");
}
else {
cy.get("[data-test=button-back-to-rounds]").click();
cy.get("[data-test=button-new-round]").should("be.visible");
cy.get("[data-test=button-new-round]").click();
cy.get("[data-test=app]").should("be.visible");
cy.get(".round").should("be.visible");
cy.logout();
cy.get("[data-test=app]").should("be.visible");
}
})
});
});
22 changes: 22 additions & 0 deletions cypress/plugins/index.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
/// <reference types="cypress" />
// ***********************************************************
// This example plugins/index.js can be used to load plugins
//
// You can change the location of this file or turn off loading
// the plugins file with the 'pluginsFile' configuration option.
//
// You can read more here:
// https://on.cypress.io/plugins-guide
// ***********************************************************

// This function is called when a project is opened or re-opened (e.g. due to
// the project's config changing)

/**
* @type {Cypress.PluginConfig}
*/
// eslint-disable-next-line no-unused-vars
module.exports = (on, config) => {
// `on` is used to hook into various events Cypress emits
// `config` is the resolved Cypress config
}
50 changes: 50 additions & 0 deletions cypress/support/commands.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,50 @@
// ***********************************************
// This example commands.js shows you how to
// create various custom commands and overwrite
// existing commands.
//
// For more comprehensive examples of custom
// commands please read more here:
// https://on.cypress.io/custom-commands
// ***********************************************
//
//
// -- This is a parent command --
// Cypress.Commands.add('login', (email, password) => { ... })
//
//
// -- This is a child command --
// Cypress.Commands.add('drag', { prevSubject: 'element'}, (subject, options) => { ... })
//
//
// -- This is a dual command --
// Cypress.Commands.add('dismiss', { prevSubject: 'optional'}, (subject, options) => { ... })
//
//
// -- This will overwrite an existing command --
// Cypress.Commands.overwrite('visit', (originalFn, url, options) => { ... })

import { users } from "./users";

Cypress.Commands.add("logout", () => {
cy.visit("/");
cy.get("[data-test=button-sign-in-out]").then(($btn) => {
if($btn.hasClass("signed-in")) {
cy.get("[data-test=button-sign-in-out]").click();
cy.get("[data-test=button-sign-out]").click();
cy.visit("/");
}
});
});

Cypress.Commands.add("login", () => {
cy.logout();

cy.get("[data-test=button-sign-in-out]").click();
cy.get("[data-test=button-email]").click();
cy.get("[data-test=input-email]").type(users.EMAIL_USER.username);
cy.get("[data-test=input-password]").type(users.EMAIL_USER.password);
cy.get("[data-test=button-sign-in]").click();
cy.wait(1000);
cy.get("[data-test=button-get-started]").click();
});
20 changes: 20 additions & 0 deletions cypress/support/index.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
// ***********************************************************
// This example support/index.js is processed and
// loaded automatically before your test files.
//
// This is a great place to put global configuration and
// behavior that modifies Cypress.
//
// You can change the location of this file or turn off
// automatically serving support files with the
// 'supportFile' configuration option.
//
// You can read more here:
// https://on.cypress.io/configuration
// ***********************************************************

// Import commands.js using ES2015 syntax:
import './commands'

// Alternatively you can use CommonJS syntax:
// require('./commands')
7 changes: 7 additions & 0 deletions cypress/support/users.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
export const users = {
EMAIL_USER: {
"description": "default persistent test user",
"username": "roundabout-test@protonmail.com",
"password": "542cE_d974b5!3ae"
}
}
Loading