GithubHelp home page GithubHelp logo

twu-biblioteca-dalzy's People

Contributors

dalzymendoza avatar

Watchers

 avatar

twu-biblioteca-dalzy's Issues

Overloaded BibliotecaApp Class; RE: Refactoring

With our BibliotecaApp class we want to keep it as minimal as possible. As you've mentioned the BibliotecaApp class is handling a lot of responsibility - it's great that you noticed that :)

When a class starts to contain logic which does not relate to its specifications it is best to create a new, more distinct representation of that object.

In OO it is good practice to name our classes after nouns which will play a role in your application. Separating our classes in this way also eases pain when a new set of eyes attempt read and understand the code.

Have a go at extracting out some of the logic into one or more new classes.

Expressive test names

A pattern that I often like to follow when naming tests is to structure them like so:

shouldDoThisWhen/IfGivenThis

This approach allows us to be more mindful when expressing exactly what we want our outcome to be.

Here is an example test name from your app:
returnCheckedOutBookUsingIncorrectId

While this provides some context it is unclear exactly what the outcome should be without looking into the code.

An example of a more expressive name could be:
shouldShowErroWhenCheckingOutWithIncorrectId

This might give the reader a little more insight into exactly what we're testing for. Of course this is only one approach to creating more expressive test names, feel free to use this or look into another way of structuring the name.

Committing IDE specific directories

The problem with committing content such as your .idea directory can be problematic for a few different reasons:

  1. You upload user/machine specific references into the repo
  2. Commit messages such as your most recent commit 'eecf4df' are difficult to inspect because of potential changes made within your IDE.
  3. Users may want to use an IDE of their choice such as Eclipse or Visual Studio Code.

I would encourage looking into .gitignore files. They're a great way of ensuring that you keep files locally which are important for you, but do not get committed into the repo.

Showing stacktraces in the console

An error message appears when I choose an option which does not any options on the starting screen.

Welcome to Biblioteca. Your one-stop-shop for great book titles in Bangalore! [M] Main Menu [Q] Quit Application 1 java.lang.NoSuchMethodException [Ljava.lang.StackTraceElement;@65b3120a

While testing our applications it's crucial for us to see where an error may be thrown and what it pertains to, but to a regular user this will appear merely as a system malfunction.

Editing Stories

When wanting to edit a story it is always necessary to provide justification regarding your decision.

That being said, having new input is always a great thing so never hesitate to question the content of a story.

In the case of this project feel free to play around with the wording, if you have issues with any of the other specifications please let me know.

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.