Skip to content

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

104 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Review Assignment Due Date

Term Project

Instructions to Setup and Run Project

Follow the steps below to install dependencies, configure your environment, seed the database, and run the project for both the server and the client.

Installing Dependencies

  1. Clone the repository.
git clone https://github.com/ckane-sbu-s25-cse316/project-s25-solo_botzhou.git
  1. Navigate to the project root directory:
cd project-s25-solo_botzhou
  1. Install dependencies for the Node server:
cd ./server
npm install
  1. Install dependencies for the React client:
cd ../client
npm install

Starting MongoDB

  1. Open a new terminal window.
  2. Start MongoDB using the appropriate command for your operating system:
  • macOS:
brew services start mongodb-community
  • Windows:
mongod

Seeding the Database

  1. Open a new terminal window and navigate to the project root:
cd project-s25-solo_botzhou
  1. Run the seeding script to seed the database. It takes four command-line arguments:
  • MongoDB URL
  • Admin email
  • Admin display name
  • Admin password

Example:

node ./server/init.js mongodb://127.0.0.1:27017/phreddit admin@phreddit.com admin 1234

Starting the Node Server

  1. Open a new terminal window and navigate to the project root for the Node server:
cd project-s25-solo_botzhou/server
  1. Start the Node server using nodemon:
nodemon server.js

Start React Client

  1. Open a new terminal window and navigate to the project root for the React client:
cd project-s25-solo_botzhou/client
  1. Start the React development server:
npm start

Running Jest Unit Tests

Running Unit Tests for Node Server

  1. Ensure both MongoDB and the Node server are running.
  2. Open a new terminal window and navigate to the project root for the Node server and run the tests:
cd project-s25-solo_botzhou/server
npm test

Running Unit Test for React Client

  1. Open a new terminal window and navigate to the project root for the React client and run the test:
cd project-s25-solo_botzhou/client
npm test

Team Member 1 Contribution

Bote Zhou

Bote developed both the front end and back end of the project, wrote unit tests, and created the UML diagrams.

About

Reddit clone!

Resources

Stars

0 stars

Watchers

0 watching

Forks

Contributors

Languages