Skip to content
Merged

Dev #363

Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
206 commits
Select commit Hold shift + click to select a range
b6a2b4e
feat: Enhance text color for better readability in KYCContent and Bad…
renulucshmi Jul 15, 2025
80d31c1
Merge branch 'dev' of https://github.com/Code102SoftwareProject/skill…
renulucshmi Jul 15, 2025
5cb190a
feat(settings): integrate user KYC form with settings page
SamFaMH Jul 15, 2025
455a320
feat: Add admin management features including create, edit, and filte…
renulucshmi Jul 16, 2025
30ef387
feat: Refactor SuspendedUsersContent component to improve structure a…
renulucshmi Jul 16, 2025
40d481a
feat: Refactor SuspendedUsersContent component for improved readabili…
renulucshmi Jul 16, 2025
078fc22
feat: Update AdminSidebar to use NotebookTabs icon for Forum Reports
renulucshmi Jul 16, 2025
fbade21
feat: Refactor reporting system with enhanced filtering and email han…
renulucshmi Jul 16, 2025
e52fa13
Merge branch 'dev' of https://github.com/Code102SoftwareProject/skill…
renulucshmi Jul 16, 2025
d32d239
feat: Add hasInstallScript property to package-lock.json
renulucshmi Jul 16, 2025
aec7399
Merge branch 'dev' of https://github.com/Code102SoftwareProject/skill…
renulucshmi Jul 16, 2025
d4127a9
feat: Add ReportDetailsModal component and enhance report filtering f…
renulucshmi Jul 16, 2025
c96d763
feat: Refactor ReportDetailsModal to use string constants for user-vi…
renulucshmi Jul 17, 2025
a456056
Merge pull request #291 from Code102SoftwareProject/main
SamFaMH Jul 17, 2025
69f4bf6
Merge pull request #292 from Code102SoftwareProject/main
SamFaMH Jul 17, 2025
2165b85
Merge pull request #293 from Code102SoftwareProject/main
SamFaMH Jul 17, 2025
ef0cd49
feat: Remove "Engagement and Activity Badges" from badge categories a…
renulucshmi Jul 17, 2025
2de2c61
Merge branch 'feat/dashboard-suggestions-profile-api-Samha' of https:…
SamFaMH Jul 17, 2025
ca39af1
Merge pull request #294 from Code102SoftwareProject/dev
SamFaMH Jul 17, 2025
1108db0
Merge branch 'feat/dashboard-suggestions-profile-api-Samha' of https:…
SamFaMH Jul 17, 2025
87f833d
Merge pull request #296 from Code102SoftwareProject/dev
AdeepaK2 Jul 17, 2025
1e5f9d8
Merge pull request #298 from Code102SoftwareProject/dev
AdeepaK2 Jul 17, 2025
9057afe
Merge branch 'dev' of https://github.com/Code102SoftwareProject/skill…
renulucshmi Jul 17, 2025
3d898a8
Merge pull request #299 from Code102SoftwareProject/test-Adeepa
AdeepaK2 Jul 17, 2025
f0f5ac6
feat: Enhance badge name validation to require a minimum length of 3 …
renulucshmi Jul 17, 2025
c0fa69b
Merge pull request #301 from Code102SoftwareProject/dev
AdeepaK2 Jul 18, 2025
909c8b5
Merge pull request #306 from Code102SoftwareProject/test-samha
SamFaMH Jul 18, 2025
8924fa4
Merge branch 'dev' of https://github.com/Code102SoftwareProject/skill…
renulucshmi Jul 18, 2025
0f010a7
Merge pull request #307 from Code102SoftwareProject/dev
SamFaMH Jul 18, 2025
138c0e0
refactor: remove MediaDeviceTips and MediaDeviceWarning components
AdeepaK2 Jul 18, 2025
d7acd20
Merge branch 'dev' of https://github.com/Code102SoftwareProject/skill…
AdeepaK2 Jul 18, 2025
26af02c
Merge pull request #308 from Code102SoftwareProject/test-Adeepa
AdeepaK2 Jul 18, 2025
f8d71b3
chore: update next and related dependencies to version 15.4.1 and sha…
renulucshmi Jul 18, 2025
e9e43e1
Merge branch 'dev' of https://github.com/Code102SoftwareProject/skill…
renulucshmi Jul 18, 2025
b6765a3
Merge pull request #309 from Code102SoftwareProject/admin-report-renu
renulucshmi Jul 18, 2025
9a24693
Add comprehensive manual test result reports for various features
renulucshmi Jul 18, 2025
18f2238
Remove obsolete test scripts for unsuspension and user population
renulucshmi Jul 18, 2025
401769d
Merge pull request #310 from Code102SoftwareProject/test-renu
renulucshmi Jul 18, 2025
795ab02
feat(api): create endpoint to fetch badges for specific user
SamFaMH Jul 18, 2025
04697d3
Merge pull request #311 from Code102SoftwareProject/dev
SamFaMH Jul 18, 2025
1f05281
Merge branch 'feat/user-dashboard' of https://github.com/Code102Softw…
SamFaMH Jul 18, 2025
68600d8
Merge pull request #312 from Code102SoftwareProject/feat/user-dashboard
SamFaMH Jul 18, 2025
3ebf7ca
Merge pull request #313 from Code102SoftwareProject/dev
SamFaMH Jul 19, 2025
33f4589
feat(kyc): add userId to KYC request and implement JWT-based user val…
renulucshmi Jul 19, 2025
205156a
Merge pull request #314 from Code102SoftwareProject/admin-report-renu
renulucshmi Jul 19, 2025
e706284
Add comprehensive tests for skill verification components and enhance…
nethmalgunawardhana Jul 19, 2025
3f90392
Merge pull request #315 from Code102SoftwareProject/jest-test
nethmalgunawardhana Jul 19, 2025
84c97ee
feat: integrate jsPDF for generating meeting notes PDF
AdeepaK2 Jul 20, 2025
3e81daf
feat: update dependencies for Quill and React-Quill
AdeepaK2 Jul 20, 2025
73136e3
fix(kyc): prevent duplicate status updates in updateStatus function
renulucshmi Jul 20, 2025
886287a
feat(kyc): add rejectionReason field to KYC schema and update handlin…
renulucshmi Jul 20, 2025
898e952
Merge branch 'dev' of https://github.com/Code102SoftwareProject/skill…
renulucshmi Jul 20, 2025
e5ea21b
feat: enhance CI configuration with mock environment variables for te…
AdeepaK2 Jul 20, 2025
91097d9
feat: update CI configuration with secure mock environment variables …
AdeepaK2 Jul 20, 2025
067141d
Merge pull request #317 from Code102SoftwareProject/Adeepa-Final-Fix
AdeepaK2 Jul 20, 2025
e85a7a1
Merge branch 'dev' of https://github.com/Code102SoftwareProject/skill…
renulucshmi Jul 20, 2025
7ec5f89
Merge pull request #319 from Code102SoftwareProject/admin-report-renu
renulucshmi Jul 20, 2025
3d8c9bf
feat: implement cancellation alerts and acknowledgment feature across…
AdeepaK2 Jul 20, 2025
b672098
Merge pull request #320 from Code102SoftwareProject/meeting-Feat-Fix-…
AdeepaK2 Jul 20, 2025
5c85940
refactor: remove obsolete test files and unsuspend user script
renulucshmi Jul 20, 2025
b4f69d3
Merge branch 'dev' of https://github.com/Code102SoftwareProject/skill…
renulucshmi Jul 20, 2025
343ecae
Merge pull request #322 from Code102SoftwareProject/admin-report-renu
renulucshmi Jul 20, 2025
375a79c
feat: enhance user restoration process to handle unique-index collisi…
renulucshmi Jul 20, 2025
9b37c27
feat: add no chat rooms message to sidebar component
AdeepaK2 Jul 20, 2025
248862b
Merge pull request #323 from Code102SoftwareProject/meeting-Feat-Fix-…
AdeepaK2 Jul 20, 2025
29f5689
Merge branch 'dev' of https://github.com/Code102SoftwareProject/skill…
renulucshmi Jul 20, 2025
f401f0e
Merge pull request #324 from Code102SoftwareProject/admin-report-renu
renulucshmi Jul 20, 2025
5cc010a
Merge pull request #325 from Code102SoftwareProject/dev
renulucshmi Jul 20, 2025
c93b4b1
Remove deprecated scripts related to admin setup, testing, and email …
renulucshmi Jul 20, 2025
883caf5
Merge branch 'dev' of https://github.com/Code102SoftwareProject/skill…
renulucshmi Jul 20, 2025
8f730b5
Merge pull request #326 from Code102SoftwareProject/admin-report-renu
renulucshmi Jul 20, 2025
ea63959
Update layout styles for AdminDashboard to ensure minimum height and …
renulucshmi Jul 20, 2025
0ce8a5a
Remove ReportingPage component and associated logic from admin report…
renulucshmi Jul 20, 2025
a4b88d8
Fix formatting issue in KYCContent component by removing unnecessary …
renulucshmi Jul 20, 2025
76cfa11
feat(api): add admin suggestion moderation endpoints (block, hide, st…
SamFaMH Jul 20, 2025
24bca3d
feat(models): add isBlocked to user and isHidden to suggestion schemas
SamFaMH Jul 20, 2025
15ea2d8
feat(admin): implement moderation panel UI with tabs and actions
SamFaMH Jul 20, 2025
d1b6a58
feat(user): disable suggestion/feedback for blocked users
SamFaMH Jul 20, 2025
a5130d3
Refactor SuspendedUsersContent component by removing delete functiona…
renulucshmi Jul 20, 2025
76749db
Add icon to UnsuspendButton for improved visual feedback
renulucshmi Jul 20, 2025
413704d
fix: avatar loading in NavBar with TS fixes and fallback
SamFaMH Jul 20, 2025
e6cd67e
Merge pull request #327 from Code102SoftwareProject/dev
SamFaMH Jul 20, 2025
3689f18
Refactor UsersContent component by updating import statements and rep…
renulucshmi Jul 20, 2025
3aa2d01
Merge branch 'feat/admin-suggestions-Samha' of https://github.com/Cod…
SamFaMH Jul 20, 2025
eb02327
Merge branch 'dev' of https://github.com/Code102SoftwareProject/skill…
renulucshmi Jul 20, 2025
5708d44
Merge pull request #328 from Code102SoftwareProject/feat/admin-sugges…
SamFaMH Jul 20, 2025
59d6548
Merge pull request #329 from Code102SoftwareProject/dev
SamFaMH Jul 20, 2025
93f1147
Merge branch 'feat/dashboard-suggestions-profile-api-Samha' of https:…
SamFaMH Jul 20, 2025
88c5c1a
Merge branch 'dev' of https://github.com/Code102SoftwareProject/skill…
renulucshmi Jul 20, 2025
31e3a9e
Merge pull request #330 from Code102SoftwareProject/admin-report-renu
renulucshmi Jul 20, 2025
2b4024b
Add refresh functionality to KYC records with a new button and update…
renulucshmi Jul 20, 2025
e68fe8c
Remove unused Circle import from KYCContent component
renulucshmi Jul 20, 2025
c10b9cf
fix(api): repair verification status fetching logic
SamFaMH Jul 20, 2025
9f92c07
feat(profile): enhance KYC status display with verified tick and reje…
SamFaMH Jul 20, 2025
74977f7
Merge pull request #331 from Code102SoftwareProject/dev
SamFaMH Jul 20, 2025
ffb3719
Merge branch 'feat/dashboard-suggestions-profile-api-Samha' of https:…
SamFaMH Jul 20, 2025
066fd8a
Merge pull request #332 from Code102SoftwareProject/feat/dashboard-su…
SamFaMH Jul 20, 2025
e630f68
Merge pull request #333 from Code102SoftwareProject/dev
SamFaMH Jul 21, 2025
a2715b4
feat(messageSystem): enhance reply functionality by fetching message …
AdeepaK2 Jul 21, 2025
4061f33
feat(db): add Message schema for storing Contact Us submissions
SamFaMH Jul 21, 2025
8f54263
feat(api): create POST /api/contact with Zod validation and DB insert
SamFaMH Jul 21, 2025
8db73ce
feat(contact): add contact form with validation and toast on submit
SamFaMH Jul 21, 2025
0d1b1e2
feat(admin-inbox): build inbox UI to view and manage messages
SamFaMH Jul 21, 2025
283f21b
feat(api): add GET/PUT /api/contact/admin for message admin actions
SamFaMH Jul 21, 2025
3deed76
style(admin-sidebar): make sidebar fixed, responsive, and add Inbox l…
SamFaMH Jul 21, 2025
a6884ef
Implement caching for admin authentication and improve session handling
renulucshmi Jul 21, 2025
15013fe
Merge pull request #334 from Code102SoftwareProject/dev
SamFaMH Jul 21, 2025
72f2f03
Merge branch 'dev' of https://github.com/Code102SoftwareProject/skill…
renulucshmi Jul 21, 2025
cf0c93d
Merge branch 'feat/contact-us-samha' of https://github.com/Code102Sof…
SamFaMH Jul 21, 2025
510d10a
Merge pull request #335 from Code102SoftwareProject/feat/contact-us-s…
SamFaMH Jul 21, 2025
98ef413
Merge pull request #336 from Code102SoftwareProject/dev
SamFaMH Jul 21, 2025
fb5bb34
Merge branch 'dev' of https://github.com/Code102SoftwareProject/skill…
renulucshmi Jul 21, 2025
94e672d
feat(privacy-terms): add Privacy Policy and Terms of Service pages wi…
AdithaBuwaneka Jul 21, 2025
4bbb633
Merge pull request #337 from Code102SoftwareProject/terms-and-privacy…
AdithaBuwaneka Jul 21, 2025
20952f5
refactor(auth): improve token expiry handling and logging
AdithaBuwaneka Jul 21, 2025
9361e8d
Merge pull request #338 from Code102SoftwareProject/Remember-me-errror
AdithaBuwaneka Jul 21, 2025
5a3019c
Refactor authentication logic in AdminDashboard component and clean u…
renulucshmi Jul 21, 2025
b49e41d
refactor: create reusable VerifiedAvatar component and integrate KYC …
SamFaMH Jul 21, 2025
d63090d
Merge pull request #339 from Code102SoftwareProject/dev
SamFaMH Jul 21, 2025
379d5dc
Merge branch 'feat/dashboard-suggestions-profile-api-Samha' of https:…
SamFaMH Jul 21, 2025
934fb8b
Merge pull request #340 from Code102SoftwareProject/feat/dashboard-su…
SamFaMH Jul 21, 2025
14bf037
Add 'Manage Inbox' permission to Admin Management Content
renulucshmi Jul 21, 2025
a53df73
Merge branch 'dev' of https://github.com/Code102SoftwareProject/skill…
renulucshmi Jul 21, 2025
289a3de
feat(avatar): enhance avatar URL processing and add localhost support…
AdithaBuwaneka Jul 21, 2025
82cc8ee
Merge branch 'dev' into google-avatar
AdithaBuwaneka Jul 21, 2025
c085334
Merge pull request #341 from Code102SoftwareProject/google-avatar
AdithaBuwaneka Jul 21, 2025
6cf08c3
refactor(ProfileCard): simplify avatar rendering and remove unused im…
AdithaBuwaneka Jul 21, 2025
7b5152e
Merge pull request #342 from Code102SoftwareProject/admin-report-renu
renulucshmi Jul 21, 2025
67f9652
fix(ProfileCard, VerifiedAvatar): update avatar URL handling for impr…
AdithaBuwaneka Jul 21, 2025
c3573e5
Merge branch 'dev' of https://github.com/Code102SoftwareProject/skill…
AdithaBuwaneka Jul 21, 2025
245e151
feat(next.config): add support for Vercel, Netlify, Heroku, and custo…
AdithaBuwaneka Jul 21, 2025
45390ec
feat(tests): add comprehensive HTML report for Authentication System …
AdithaBuwaneka Jul 21, 2025
42785f2
feat(tests): add Skills Management test results HTML report
AdithaBuwaneka Jul 21, 2025
bd15eed
feat(tests): add comprehensive HTML report for Skill Listings test re…
AdithaBuwaneka Jul 21, 2025
6282b67
feat(tests): add comprehensive HTML report for Skill Matching System …
AdithaBuwaneka Jul 21, 2025
bf436ff
feat(tests): add comprehensive HTML report for Homepage Design & Feat…
AdithaBuwaneka Jul 21, 2025
39122d7
feat(tests): add comprehensive HTML report for Admin Success Stories …
AdithaBuwaneka Jul 21, 2025
63bbe78
Merge pull request #343 from Code102SoftwareProject/manual-testing
AdithaBuwaneka Jul 21, 2025
8dcfa0f
feat(chat): add URL parameter handling for dashboard navigation and f…
AdeepaK2 Jul 21, 2025
03dca33
Merge branch 'dev' of https://github.com/Code102SoftwareProject/skill…
AdeepaK2 Jul 21, 2025
d8f42f9
feat(dashboard): enhance ListingsContent to navigate to skills section
AdithaBuwaneka Jul 21, 2025
b72398d
Merge pull request #344 from Code102SoftwareProject/listion-part-errros
AdithaBuwaneka Jul 21, 2025
a0ccc6f
Add sorting functionality to Suspended Users list and update UI
renulucshmi Jul 21, 2025
40d1659
Merge pull request #345 from Code102SoftwareProject/dev
SamFaMH Jul 21, 2025
cdcf399
feat(meeting-notifications): implement email notification tracking fo…
AdeepaK2 Jul 21, 2025
636f069
Merge branch 'dev' of https://github.com/Code102SoftwareProject/skill…
AdeepaK2 Jul 21, 2025
bfc4bcc
Add HTML test reports for Forum Reports, Skill Category Manager, and …
nethmalgunawardhana Jul 21, 2025
e6c6700
Merge branch 'dev' of https://github.com/Code102SoftwareProject/skill…
nethmalgunawardhana Jul 21, 2025
16af6b8
feat(tests): add HTML report for Skill Verification Test Results
nethmalgunawardhana Jul 21, 2025
b232f5d
personalizedfeed manual test added
nethmalgunawardhana Jul 21, 2025
93c1cf3
refactor(SuccessStoriesCarousel): remove small cards preview for succ…
AdithaBuwaneka Jul 21, 2025
9a1cfe0
Merge branch 'dev' of https://github.com/Code102SoftwareProject/skill…
AdithaBuwaneka Jul 21, 2025
ef81e9d
feat(Footer): restructure layout and enhance content with new links a…
AdithaBuwaneka Jul 21, 2025
482d3fe
feat(TrendingSkills): enhance call to action with dynamic content bas…
AdithaBuwaneka Jul 21, 2025
38b8a2f
fix : fixed the issues in search bar, connect with support link
SamFaMH Jul 21, 2025
54ae2e4
Merge pull request #348 from Code102SoftwareProject/dev
SamFaMH Jul 21, 2025
0294dd7
Merge branch 'feat/dashboard-suggestions-profile-api-Samha' of https:…
SamFaMH Jul 21, 2025
ca44acf
Merge pull request #349 from Code102SoftwareProject/feat/dashboard-su…
SamFaMH Jul 21, 2025
dc085ad
Enhance UI consistency by updating text colors in various admin compo…
renulucshmi Jul 21, 2025
c3b43b0
Merge branch 'dev' of https://github.com/Code102SoftwareProject/skill…
renulucshmi Jul 21, 2025
adf923a
feat: refactor success stories to feedback entries, update related co…
AdithaBuwaneka Jul 21, 2025
ff70a34
Merge pull request #350 from Code102SoftwareProject/sucess-stories
AdithaBuwaneka Jul 21, 2025
225de04
fix: improve session timer management in AuthProvider
AdithaBuwaneka Jul 21, 2025
79cf51e
Refactor permissions display in AdminEditModal for role-based access …
renulucshmi Jul 21, 2025
d595dee
Merge branch 'dev' of https://github.com/Code102SoftwareProject/skill…
renulucshmi Jul 21, 2025
dc072a0
refactor: streamline ChatPage component and enhance user status handl…
AdeepaK2 Jul 21, 2025
d9e9b3b
refactor: streamline notification confirmation and update success mes…
renulucshmi Jul 21, 2025
f2f80ea
Merge branch 'dev' of https://github.com/Code102SoftwareProject/skill…
renulucshmi Jul 21, 2025
12f1376
feat: add dynamic rendering for AdminLoginPage and ChatPage, enhance …
AdeepaK2 Jul 21, 2025
92a5ab2
refactor: add dynamic export to AdminLoginPage for improved rendering
renulucshmi Jul 21, 2025
90e853d
Merge branch 'dev' of https://github.com/Code102SoftwareProject/skill…
renulucshmi Jul 21, 2025
eabbc1e
Merge pull request #351 from Code102SoftwareProject/admin-report-renu
renulucshmi Jul 21, 2025
e80bd63
feat: implement session timeline and milestones display in ProgressTa…
AdeepaK2 Jul 21, 2025
5ba8131
Merge branch 'dev' of https://github.com/Code102SoftwareProject/skill…
AdeepaK2 Jul 21, 2025
edc4b03
feat: enhance success stories management with detailed logging, user …
AdithaBuwaneka Jul 21, 2025
96c65e8
ux: enhance search bar positioning and table layout for better usability
SamFaMH Jul 21, 2025
de6fe42
Merge pull request #352 from Code102SoftwareProject/dev
SamFaMH Jul 21, 2025
b12ee7c
Merge branch 'feat/dashboard-suggestions-profile-api-Samha' of https:…
SamFaMH Jul 21, 2025
839009c
refactor: remove outdated comments from badge assignment scheduler
renulucshmi Jul 21, 2025
f6e4d01
Merge pull request #353 from Code102SoftwareProject/feat/dashboard-su…
SamFaMH Jul 21, 2025
bc65717
refactor: remove full name validation and update display logic in KYC…
renulucshmi Jul 21, 2025
1fcfc13
Merge branch 'dev' of https://github.com/Code102SoftwareProject/skill…
renulucshmi Jul 21, 2025
228f343
Merge pull request #354 from Code102SoftwareProject/admin-report-renu
renulucshmi Jul 21, 2025
5fe6d43
fix: update regex for new NIC format validation
renulucshmi Jul 21, 2025
fc0d016
feat: enhance success stories display with improved user name handlin…
AdithaBuwaneka Jul 21, 2025
f7b2c07
Merge pull request #355 from Code102SoftwareProject/admin-sucessstories
AdithaBuwaneka Jul 21, 2025
1b7f7ff
Merge branch 'dev' of https://github.com/Code102SoftwareProject/skill…
renulucshmi Jul 21, 2025
80759f5
Merge pull request #356 from Code102SoftwareProject/admin-report-renu
renulucshmi Jul 21, 2025
8f000c8
test: enhance KYCContent tests with loading state and error handling
renulucshmi Jul 21, 2025
2f5fc70
Merge pull request #357 from Code102SoftwareProject/test-renu
renulucshmi Jul 21, 2025
02fb5e4
style: adjust layout of Success Stories container for better alignment
AdithaBuwaneka Jul 21, 2025
e99437e
refactor: simplify session management by removing useCallback for han…
AdithaBuwaneka Jul 21, 2025
c0c8049
style: improve layout of skill card by restructuring title and status…
AdithaBuwaneka Jul 21, 2025
9719fe5
feat: enhance skills management with filtering, sorting, and statistics
AdithaBuwaneka Jul 21, 2025
6e3b9bc
feat: implement custom dropdowns for mobile responsiveness and enhanc…
AdithaBuwaneka Jul 21, 2025
0cb3280
feat: add custom dropdowns for mobile responsiveness and enhance filt…
AdithaBuwaneka Jul 21, 2025
7c3039f
Merge pull request #358 from Code102SoftwareProject/my-skill-ui-update
AdithaBuwaneka Jul 21, 2025
8b03c19
feat: Enhance Matches Page with Filtering, Searching, and Statistics
AdithaBuwaneka Jul 22, 2025
401e91f
Merge pull request #359 from Code102SoftwareProject/skilll-amtches-ui…
AdithaBuwaneka Jul 22, 2025
79478f5
feat: Add KYC status fetching for users in ListingCard, MatchCard, an…
AdithaBuwaneka Jul 22, 2025
b14658b
feat: implement admin authentication and permissions verification for…
nethmalgunawardhana Jul 22, 2025
d1cc9c3
Merge branch 'dev' of https://github.com/Code102SoftwareProject/skill…
nethmalgunawardhana Jul 22, 2025
0622e4e
Merge pull request #361 from Code102SoftwareProject/user-verificstion…
AdithaBuwaneka Jul 22, 2025
f27659d
test: enhance AdminReports tests with improved error handling, fetchi…
renulucshmi Jul 22, 2025
5c3a4f9
Merge branch 'dev' of https://github.com/Code102SoftwareProject/skill…
renulucshmi Jul 22, 2025
34af9e8
Merge pull request #362 from Code102SoftwareProject/test-renu
renulucshmi Jul 22, 2025
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
68 changes: 68 additions & 0 deletions .github/workflows/ci-build-check.yml
Original file line number Diff line number Diff line change
Expand Up @@ -38,12 +38,80 @@ jobs:
continue-on-error: false
env:
CI: true
# Database
MONGODB_URI: mongodb://localhost:27017/test-db

# JWT & Auth
JWT_SECRET: dd8a48e6f99d7b4c3b6a4c7e9587a2cc7f8b9e3a1d5f6g8h2j3k4m5n6p7q8r9t1u2v3w4x5y6z7-ci-test
ADMIN_JWT_SECRET: d8da04f2c803f88c68e38c47bad261223d01cc73e5f89d15e02bbf9f858f53b0f7220e5c23eb1f34ad355f821298d196-ci-test
M_KEY: e685b3de592422cdceff763ca3e784a2c792e4e7e5984cf0ea86544555612b80-ci-test

# Mock external services for testing
R2_ACCESS_KEY_ID: mock-r2-access-key-id
R2_SECRET_ACCESS_KEY: mock-r2-secret-access-key
R2_ACCOUNT_ID: mock-r2-account-id
R2_BUCKET_NAME: mock-test-bucket
R2_ENDPOINT: https://mock-endpoint.r2.cloudflarestorage.com

SENDGRID_API_KEY: SG.mock-sendgrid-api-key-for-testing-only
SENDGRID_FROM_EMAIL: test@example.com
DAILY_API_KEY: mock-daily-api-key-for-testing-only
GOOGLE_CLIENT_ID: mock-google-client-id
GOOGLE_CLIENT_SECRET: mock-google-client-secret
GEMINI_API_KEY: mock-gemini-api-key-for-testing-only
SYSTEM_API_KEY: mock-system-api-key-for-testing-only

# Test environment
NODE_ENV: test
NEXT_TELEMETRY_DISABLED: 1

- name: Build application
run: npm run build
continue-on-error: false
env:
CI: true
# Database
MONGODB_URI: mongodb://localhost:27017/test-db

# JWT & Auth - Make sure these are long enough and properly formatted
JWT_SECRET: dd8a48e6f99d7b4c3b6a4c7e9587a2cc7f8b9e3a1d5f6g8h2j3k4m5n6p7q8r9t1u2v3w4x5y6z7-ci-build
ADMIN_JWT_SECRET: d8da04f2c803f88c68e38c47bad261223d01cc73e5f89d15e02bbf9f858f53b0f7220e5c23eb1f34ad355f821298d196-ci-build
M_KEY: e685b3de592422cdceff763ca3e784a2c792e4e7e5984cf0ea86544555612b80-ci-build

# Cloudflare R2 Storage
R2_ACCESS_KEY_ID: mock-r2-access-key-id
R2_SECRET_ACCESS_KEY: mock-r2-secret-access-key
R2_ACCOUNT_ID: mock-r2-account-id
R2_BUCKET_NAME: mock-skillswaphub-bucket
R2_ENDPOINT: https://mock-endpoint.r2.cloudflarestorage.com

# Email Services
SENDGRID_API_KEY: SG.mock-sendgrid-api-key-for-ci-build-only
SENDGRID_FROM_EMAIL: test@example.com
MEETING_NOTI_MAIL: test@example.com
MEETING_NOTI_PW: mock-email-password

# Daily.co Video
DAILY_API_KEY: mock-daily-api-key-for-ci-build-only

# Google OAuth
GOOGLE_CLIENT_ID: mock-google-client-id.apps.googleusercontent.com
GOOGLE_CLIENT_SECRET: mock-google-client-secret
NEXT_PUBLIC_GOOGLE_CLIENT_ID: mock-google-client-id.apps.googleusercontent.com

# AI Service
GEMINI_API_KEY: mock-gemini-api-key-for-ci-build-only

# System API
SYSTEM_API_KEY: mock-system-api-key-for-ci-build-only

# Socket Connection
NEXT_PUBLIC_SOCKET: https://mock-socket-server.example.com/

# Build Configuration - Use 'ci' instead of 'production' to avoid production validations
NODE_ENV: ci
NEXT_TELEMETRY_DISABLED: 1
SKIP_DB_VALIDATION: true

- name: Check build output
run: |
Expand Down
Empty file removed Enhanced-Suspension-Test-Guide.md
Empty file.
Empty file removed SUSPENSION-POPUP-SUMMARY.md
Empty file.
192 changes: 192 additions & 0 deletions __tests__/components/Admin/ForumReports.test.tsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,192 @@
/**
* Admin Forum Reports Tests
* Test suite for the admin forum report management functionality
*/

import React from 'react';
import { render, screen, fireEvent, waitFor } from '@testing-library/react';
import '@testing-library/jest-dom';
import userEvent from '@testing-library/user-event';
import ForumReportsContent from '@/components/Admin/dashboardContent/ForumReportsContent';
import Swal from 'sweetalert2';

// Mock dependencies
jest.mock('sweetalert2', () => ({
__esModule: true,
default: {
fire: jest.fn(() => Promise.resolve({ isConfirmed: true })),
close: jest.fn()
}
}));

// Mock fetch
global.fetch = jest.fn();
const mockFetch = global.fetch as jest.MockedFunction<typeof global.fetch>;
const mockSwal = Swal as jest.Mocked<typeof Swal>;

describe('Admin Forum Reports Component', () => {
const mockReports = [
{
_id: 'report-1',
postId: {
_id: 'post-1',
title: 'Inappropriate Post',
content: 'This is an inappropriate post content',
author: { _id: 'user-1' },
likes: 5,
dislikes: 10,
replies: 2,
views: 100,
createdAt: '2023-06-15T10:00:00Z'
},
reportedBy: {
_id: 'user-2',
firstName: 'Jane',
lastName: 'Doe',
email: 'jane@example.com',
avatar: 'avatar.jpg'
},
reportType: 'inappropriate_content',
description: 'This post contains inappropriate content',
status: 'pending',
priority: 'high',
aiAnalysis: {
isAnalyzed: true,
analysisResult: 'potentially_harmful',
confidence: 0.85,
detectedIssues: ['offensive language', 'adult content'],
summary: 'Post contains potentially offensive content',
recommendedAction: 'review',
analysisDate: '2023-06-15T10:30:00Z',
modelUsed: 'Gemini 2.0'
},
postSnapshot: {
title: 'Inappropriate Post',
content: 'This is an inappropriate post content',
authorId: 'user-1',
authorName: 'John Smith',
forumId: 'forum-1',
forumTitle: 'General Discussion',
capturedAt: '2023-06-15T10:15:00Z'
},
createdAt: '2023-06-15T10:15:00Z'
},
{
_id: 'report-2',
postId: {
_id: 'post-2',
title: 'Spam Post',
content: 'This is spam content',
author: { _id: 'user-3' },
likes: 0,
dislikes: 15,
replies: 0,
views: 30,
createdAt: '2023-06-14T09:00:00Z'
},
reportedBy: {
_id: 'user-4',
firstName: 'Alice',
lastName: 'Johnson',
email: 'alice@example.com'
},
reportType: 'spam',
description: 'This post is spam',
status: 'under_review',
priority: 'medium',
aiAnalysis: {
isAnalyzed: true,
analysisResult: 'harmful',
confidence: 0.92,
detectedIssues: ['spam', 'promotional content'],
summary: 'Post is likely spam',
recommendedAction: 'remove',
analysisDate: '2023-06-14T09:30:00Z',
modelUsed: 'Gemini 2.0'
},
adminId: {
_id: 'admin-1',
username: 'admin',
email: 'admin@example.com'
},
postSnapshot: {
title: 'Spam Post',
content: 'This is spam content',
authorId: 'user-3',
authorName: 'Bob Williams',
forumId: 'forum-1',
forumTitle: 'General Discussion',
capturedAt: '2023-06-14T09:15:00Z'
},
createdAt: '2023-06-14T09:15:00Z'
}
];

const mockPagination = {
currentPage: 1,
totalPages: 1,
totalCount: 2,
hasNext: false,
hasPrev: false
};

beforeEach(() => {
jest.clearAllMocks();

// Default mock responses
mockFetch.mockResolvedValue({
ok: true,
json: async () => ({
success: true,
data: {
reports: mockReports,
pagination: mockPagination,
statusSummary: {
pending: 1,
under_review: 1,
resolved: 0,
dismissed: 0,
auto_resolved: 0
},
aiSummary: {
safe: 0,
potentially_harmful: 1,
harmful: 1,
requires_review: 0
}
}
}),
} as Response);
});

// Test Case 1: Component renders and displays reports
test('renders forum reports dashboard and displays reports', async () => {
render(<ForumReportsContent />);

// Check for loading spinner initially
const loadingSpinner = document.querySelector('.animate-spin');
expect(loadingSpinner).toBeInTheDocument();

// Wait for reports to load
await waitFor(() => {
expect(screen.getByText('Forum Post Reports')).toBeInTheDocument();
});

// Check that reports are displayed
expect(screen.getByText('Inappropriate Post')).toBeInTheDocument();
expect(screen.getByText('Spam Post')).toBeInTheDocument();

// Check that status filters are displayed
expect(screen.getByRole('option', { name: 'All Status' })).toBeInTheDocument();
expect(screen.getByRole('option', { name: 'Pending' })).toBeInTheDocument();
expect(screen.getByRole('option', { name: 'Under Review' })).toBeInTheDocument();

// Check that priority badges are displayed
expect(screen.getByText('HIGH')).toBeInTheDocument();
expect(screen.getByText('MEDIUM')).toBeInTheDocument();

// Check that AI analysis results are displayed
expect(screen.getByText('potentially harmful')).toBeInTheDocument();
expect(screen.getByText('harmful')).toBeInTheDocument();
});
});
Loading
Loading