Git Product home page Git Product logo

pmb-test's Introduction

README

Installation:

  • bin/setup
  • bin/rails s

It will install gems, create database and populate it with some initial messages

Rspec

As rspec uses poltergeist as js driver you may need to install phatnomjs

  • brew cask install phantomjs

To run tests type

  • bundle exec rspec

There are 2 typee of specs:

  1. Integration (lays under spec/features)
  2. Unit (currently only one spec for ActionCable. Lays under spec/commands)

Note: I did not write specs for controller since we have integration specs which covers controller functionality

What included?

  • Visitor/user could see all messages on page (pagination included)
  • Visitor/user could create/update/delete messages
  • Visitor could update/delete all anonymous messages (could be handled by session to make behavior like visitor is authenticated in future)
  • User could update/delete his own messages
  • Visitor/user could open many tabs and see page updates in each of them without page reload (ActionCable is used as messaging basis)
  • Validation errors is rendered by json (Errors could be shown on page in future if needed)

Note

There are couple of known design bugs (e.g if we add message on full board). We could fix it by js handling index method but I thought it's a bit excess in terms of the task

pmb-test's People

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.