Coder Social home page Coder Social logo

launch-mod2-animaltracker's Introduction

Mod2 Week2 Assessment -

Setup

  1. Fork this repository.
  2. Add ONE of the following GitHub profiles as a collaborator to your forked repo: memcmahon, rtillies, zoefarrell
  3. Clone your repo to your local machine.
  4. Open your cloned repository in Visual Studio.
  5. Insert your name on line 1 to replace <YOUR NAME HERE> above.

Questions (10 Points Possible)

Important Answer these questions in this file on your main branch. When finished with the questions, commit and push your main branch. You do not need to create a pull request yet!

  1. What does TDD stand for?

  2. What are three benefits of using TDD?

  3. Imagine you are in an interview. The interviewer asks: How do you use TDD? How would you answer?

  4. For the class below, outline the tests you would need. Try to use as much C# syntax as possible. The first test has been provided for you. (this question is worth 4 points)

public class Dog
    {
        public string Name { get; }
        public string Breed { get; }
        public bool IsHungry { get; private set; }

        public Dog(string name, string breed)
        {
            Name = name;
            Breed = breed;
            IsHungry = true;
        }

        public void Eat()
        {
            IsHungry = false;
        }

        public void Sleep()
        {
            IsHungry = true;
        }

        public string Speak()
        {
            return "Bark Bark!";
        }
    }
// Add your tests here

[Fact]
public void DogHasNameAttribute()
{
    Dog dog = new Dog("Nile", "Golden Retriever");

    Assert.Equal("Nile", dog.Name);
}
  1. What is a merge conflict, and when might you encounter one?

  2. You and a partner are working on a project together. Your partner is working on aa-branch; you are working on bb-branch. In as much detail as possible, describe how you both would get your work combined onto the main branch.

  3. Why is it good practice to have someone else approve and/or merge your PR?

Before moving on to the next section, commit your work and push your main branch!

Git Exercise (6 points possible)

  1. Create a new branch called elephants (1 point)

  2. Add the following to the end of the Animal Tracker file:

Elephants
- African Savanna
- Asian
- African Forest
  1. Commit this change to the Animal Tracker file with an appropriate message. (1 point)

  2. Create the following files with the listed contents:

African Savanna.txt

Average shoulder height: 2.6-3.2 meters
Average mass: 3.3-6.6 short tons

Asian Elephant.txt

Average shoulder height: 2.4-2.8 meters
Average mass: 3.0-4.4 short tons

African Forest Elephant.txt

Average shoulder height: 1.8-3.0 meters
Average mass: 2,000-7,000 kilograms
  1. Add and Commit these new files with an appropriate message. (1 point)

  2. Push your elephants branch to GitHub. (1 point)

  3. Create a Pull Request in GitHub. Write a short description of the changes you made to the repo. (1 point)

  4. Request a review from your collaborator. (1 point)

Submission

Submit the Assessment Submission form linked in your cohort slack channel!

Rubric

This assessment has a total of 16 Points. Earning 11 or more points is a pass and will indicate that you are progressing well with the material.

As a reminder, this assessment is for students and instructors to determine if there are any areas that need additional reinforcement!

launch-mod2-animaltracker's People

Contributors

rtillies avatar memcmahon avatar

Watchers

 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.