Skip to content

Commit

Permalink
Added documentation for unit tests
Browse files Browse the repository at this point in the history
  • Loading branch information
Shyam-Sundar-Raju committed Feb 24, 2025
1 parent edcb270 commit 31d19ab
Show file tree
Hide file tree
Showing 2 changed files with 38 additions and 5 deletions.
26 changes: 22 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,8 @@ Ensure the following requirements are met before using the application:
- **Development Environment**:
- **Golang** must be installed on your system.
- Ensure a working **Go Compiler** is set up.
- **golangci** must be installed for testing (optional) using the command:
```go install github.com/golangci/golangci-lint/cmd/golangci-lint@latest```

---

Expand All @@ -35,7 +37,23 @@ git clone https://github.com/CSE-25/amrita_pyq

---

### Step 3: Run the Application
### Step 3: Run Unit Test
To run all the unit tests for this project use the following command:
```bash
go test ./... -v
```

You will be able to see the output and status for each unit test available.

### Run Lint check
```bash
golangci-lint run
```
**Note:** This command will return an output only when it finds an error. Otherwise, no visible change occurs.

---

### Step 4: Run the Application
1. Open the `main.go` file in your preferred code editor (eg:VS Code).
2. Execute the application:
```bash
Expand All @@ -48,7 +66,7 @@ git clone https://github.com/CSE-25/amrita_pyq

---

### Step 4: Select an Option
### Step 5: Select an Option
1. Use the menu to choose an option.
2. The tool will process your request and fetch the desired question paper.

Expand All @@ -60,7 +78,7 @@ git clone https://github.com/CSE-25/amrita_pyq
---


### Step 5: View the Question Paper
### Step 6: View the Question Paper
1. **Filter**: Use the `/` key to apply a filter and narrow down the list of PDFs.
2. The question paper will automatically open as a **PDF** in your default web browser.

Expand All @@ -75,7 +93,7 @@ The File is opened in PDF format in your default browser(in this case, Microsoft

---

### Step 6: Continue or Exit
### Step 7: Continue or Exit
After the PDF is displayed, you will have the following options:
- **Go Back to Main Menu**: Select `Back to Main Menu` to return to the main menu.
- **Exit**: Use the `Quit` option in the menu to close the application.
Expand Down
17 changes: 16 additions & 1 deletion docs/getting-started.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ Before you begin, ensure you have the following:
- **Development Environment**:
- **Golang** installed on your system.
- A working **Go Compiler**.
- **golangci** installed on your system (Recommended for testing).

## Installation

Expand All @@ -23,7 +24,21 @@ Clone the repository to your local machine. Open a terminal and run:
git clone https://github.com/CSE-25/amrita_pyq
```

### Step 2: Run the Application
### Step 2: Run Unit Test
To run all the unit tests for this project use the following command:
```bash
go test ./... -v
```

If all unit tests are passed you are good to go!!

### Run Lint check
```bash
golangci-lint run
```
**Note:** This command will return an output only when it finds an error. Otherwise, no visible change occurs.

### Step 3: Run the Application

1. Open the terminal and navigate to the cloned repository directory:
```sh
Expand Down

0 comments on commit 31d19ab

Please sign in to comment.