Skip to content

test: add unit tests for SwocProjectModal#454

Merged
andoriyaprashant merged 1 commit into
andoriyaprashant:mainfrom
adityashirsatrao007:test/swoc-project-modal
Jun 3, 2026
Merged

test: add unit tests for SwocProjectModal#454
andoriyaprashant merged 1 commit into
andoriyaprashant:mainfrom
adityashirsatrao007:test/swoc-project-modal

Conversation

@adityashirsatrao007

Copy link
Copy Markdown
Contributor

Description

Adds comprehensive unit tests for the SwocProjectModal class.

Changes

  • Added test/swoc_project_modal_test.dart with 9 test cases covering:
    • Constructor field initialization
    • copyWith() with partial and full updates
    • toMap() serialization
    • fromMap() deserialization
    • getDataFromJson() factory method
    • toJson() JSON encoding
    • toString() output
    • Edge case: empty techstack list

Related Issue

Contributes to #417 (improving test coverage and code quality)

Type of Change

  • New feature (adding tests)

Checklist

  • Tests pass locally
  • Code follows project style guidelines

Add comprehensive unit tests for the SwocProjectModal class covering:
- Constructor field initialization
- copyWith() method with partial and full updates
- toMap() serialization
- fromMap() deserialization
- getDataFromJson() factory method
- toJson() JSON encoding
- toString() output
- Edge case: empty techstack list

Closes #417
Copilot AI review requested due to automatic review settings May 30, 2026 10:54
@netlify

netlify Bot commented May 30, 2026

Copy link
Copy Markdown

Deploy Preview for aquamarine-kheer-83feda failed. Why did it fail? →

Name Link
🔨 Latest commit 6a88320
🔍 Latest deploy log https://app.netlify.com/projects/aquamarine-kheer-83feda/deploys/6a1ac2020c2998000883b3fd

@github-actions

Copy link
Copy Markdown

Thank you for submitting your pull request! We'll review it as soon as possible.

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Note

Copilot was unable to run its full agentic suite in this review.

Adds unit tests for the SwocProjectModal class covering construction, serialization, and copy semantics.

Changes:

  • New test file with 9 test cases for SwocProjectModal.
  • Covers constructor, copyWith, toMap/fromMap, getDataFromJson, toJson, toString, and empty techstack.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@andoriyaprashant andoriyaprashant merged commit 5eacbd5 into andoriyaprashant:main Jun 3, 2026
1 of 5 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants