Skill-Share by ZenWare
Team
- E/23/035, Irusha Bandara, email
- E/23/104, Poorna Gamage, email
- E/23/430, Hiruni Weerasinghe, email
- E/23/317, Sashika Rathnayake, email
Table of Contents
Introduction
In today’s academic environments, students often possess valuable skills but lack a structured way to share them, leading to underutilized peer knowledge. Current methods for finding mentors or study partners are inefficient, relying on manual coordination and failing to solve complex scheduling conflicts. Skill-Share by ZenWare addresses this by providing a campus-oriented, full-stack platform that uses smart algorithms to connect students.
The solution goes beyond simple searching; it identifies multi-user “skill cycles” (where Student A teaches B, and B teaches C) and automatically syncs free time slots to eliminate scheduling headaches. By integrating a Trust Score System and real-time communication, it builds a reliable learning community.
The impact is a more connected university ecosystem where learning is accessible and collaborative. It empowers students to trade knowledge as a resource, reducing reliance on expensive external tutoring and maximizing the collective potential of the student body.
Solution Architecture
The platform is engineered to solve a specific campus problem: the “hidden” skills of university students. The architecture transitions users from an inefficient “As-Is” state (relying on WhatsApp, paid materials, or unreliable AI) to a secure, centralized peer-to-peer network. At a high level, the system utilizes JWT authentication for secure access, connecting users through a live auto-suggest search engine (by user or skill) and managing interactions via an automated availability and notification system.
Software Designs
Our software design centers on empowering the user rather than forcing automated matches. We originally designed a “Skill-Cycle” algorithm, but identified critical edge cases: unacceptable wait times, infinite relationship loops, and the restriction that a user must both teach and learn. To resolve this, we pivoted to a decentralized Credit and Reputation Economy.
- Core Mechanics: Users manage their own availability and book individual sessions.
- The Economy: To learn a skill, users spend credits. To earn credits, they are incentivized to teach others. This gamifies the peer-to-peer process and completely eliminates the bottleneck of waiting for a perfect “match cycle.”
- Two-Way Feedback: Completed sessions use a dual-feedback submission design to calculate a reliable user reputation score.
System Use Case Diagram
System Class Diagram
Testing
1. Phase - 1
Testing focused heavily on our core custom logic and security. We executed comprehensive unit and integration tests to ensure that our JWT security filters, real-time Notification system, and complex Credit Score economy (ensuring credits are correctly deducted or awarded during bookings) functioned flawlessly under various edge cases.
2. Phase - 2
This section summarizes the automated testing that has been implemented and executed within the SkillShare system. The project is divided into a Java Spring Boot backend (skillshare-backend) and a React TypeScript frontend (skillshare-frontend-new). Both systems contain foundational test setups, with focused unit tests on critical business logic for the backend and API interaction mocks for the frontend.
1. Backend Testing (skillshare-backend)
The backend testing utilizes JUnit 5 and Mockito for unit and integration testing.
Existing Tests
SessionServiceTest.java:- A dedicated unit test for the
SessionServicebusiness logic. - Mocks Used:
SessionRepository,UserRepository,SkillRepository,AvailabilityRepository,NotificationService, andSecurityContextHolder. - Test Cases Covered:
testBookSession_Success: Validates that a session is successfully booked, user credits are deducted (-10), availability is marked as booked, and a notification is sent to the mentor.testBookSession_InsufficientCredits: Asserts that anIllegalStateExceptionis thrown if a learner tries to book a session with insufficient credits (e.g., 5 credits).testCompleteSession_BeforeEndTime: Asserts that a session cannot be completed prematurely before its scheduled end time.
- A dedicated unit test for the
SkillshareBackendApplicationTests.java:- A standard Spring Boot integration test that verifies the application context loads successfully without dependency injection failures.
2. Frontend Testing (skillshare-frontend-new)
The frontend testing is powered by Vitest, an extremely fast unit-testing framework tailored for Vite-based projects.
Existing Tests
api.test.ts(src/lib/api.test.ts):- Tests the
usersApi.getMe()function. - Mocks Used: Global
fetchAPI is mocked usingvi.fn()to prevent real network requests.localStorageis mocked to simulate JWT token retrieval. - Test Cases Covered:
- Success Path: Verifies that the
/api/users/meendpoint is called with the correctAuthorizationandContent-Typeheaders, successfully parsing and returning the mock user object. - Error Path: Verifies that the function correctly throws an
ApiErrorwhen the server responds with a401 Unauthorizedstatus.
- Success Path: Verifies that the
- Tests the
example.test.ts(src/test/example.test.ts):- A foundational boilerplate test ensuring the Vitest environment is correctly configured and operational.
Test Execution Results
The frontend test suite was executed successfully with the following results:
✓ src/test/example.test.ts (1 test) 2ms
✓ src/lib/api.test.ts (2 tests) 4ms
Test Files 2 passed (2)
Tests 3 passed (3)
Duration 1.48s
3. Recommendations & Next Steps
Backend Next Steps:
- Expand test coverage to other core services like
UserServiceandGamificationService. - Add integration/controller tests (e.g.,
MockMvc) forFeedbackControllerandSessionControllerto ensure API endpoints return correct HTTP statuses.
Frontend Next Steps:
- Introduce React Testing Library to test UI components. Currently, components like
CreateProfile.tsxandViewProfile.tsxlack render and interaction tests. - Add E2E (End-to-End) testing using Playwright or Cypress to test the entire user flow from authentication to session booking.
Conclusion
Having successfully delivered our MVP, we have aggressively expanded Skill-Share into a feature-rich, production-ready architecture.
- Core Foundation Achieved: We established a secure, robust platform featuring standard authentication, user dashboards, live skill searching, individual session booking, a custom credit/reputation economy, and a dual-feedback system.
- Final Product Capabilities (Milestone 3): Moving beyond the MVP, we successfully engineered and integrated advanced systems, including a real-time STOMP WebSocket Chat infrastructure, an atomic Gamification Engine (XP, Leveling, and Trending Leaderboards), a peer-to-peer Friend Request network, secure profile picture uploads with Zero-Trust validation, and seamless OAuth2 integration.
- Future Roadmap & Deployment: As we finalize the product, our immediate focus shifts towards deploying the full-stack architecture to live cloud environments. Further ecosystem expansions will include Group Sessions, a Course Pool, deeper Google Workspace integrations (e.g., Calendar syncing), and a dedicated Admin authorization tier to manage the platform at scale.