Skip to content

Commit

Permalink
Merge pull request #235 from gruz0/feature/add-two-weeks-plan-generator
Browse files Browse the repository at this point in the history
Add two-weeks plan generator
  • Loading branch information
gruz0 authored Jan 19, 2025
2 parents ff79b24 + d01f9ad commit 070b28c
Show file tree
Hide file tree
Showing 19 changed files with 2,264 additions and 20 deletions.
88 changes: 88 additions & 0 deletions __tests__/idea/domain/Aggregate.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ import { ProductName } from '@/idea/domain/ProductName'
import { SWOTAnalysis } from '@/idea/domain/SWOTAnalysis'
import { SocialMediaCampaigns } from '@/idea/domain/SocialMediaCampaigns'
import { TargetAudience } from '@/idea/domain/TargetAudience'
import { TestingPlan } from '@/idea/domain/TestingPlan'
import { ValueProposition } from '@/idea/domain/ValueProposition'
import { Identity } from '@/shared/Identity'

Expand Down Expand Up @@ -657,4 +658,91 @@ describe('Idea Class', () => {
expect(idea.isArchived()).toBeTrue()
})
})

describe('setTestingPlan', () => {
let idea: Idea
let testingPlan: TestingPlan

beforeEach(() => {
idea = Idea.New(
validId,
validConceptId,
validProblem,
validMarketExistence,
validTargetAudiences
)
testingPlan = TestingPlan.New(
[{ assumption: 'test', whyCritical: 'test', validationMethod: 'test' }],
Array.from({ length: 14 }, (_, i) => ({
day: i + 1,
focus: 'test',
tasks: ['test'],
successMetrics: ['test'],
toolsNeeded: ['test'],
estimatedTime: 'test',
})),
{
qualitative: ['test'],
quantitative: ['test'],
minimumSuccessCriteria: ['test'],
},
[
{
method: 'test',
description: 'test',
whenToUse: 'test',
expectedOutcome: 'test',
},
],
[{ scenario: 'test', solution: 'test', alternativeApproach: 'test' }],
{
minimumBudget: 'test',
timeSavingTips: ['test'],
freeTools: ['test'],
paidAlternatives: ['test'],
},
{
platforms: ['test'],
preparationSteps: ['test'],
timing: 'test',
engagementTactics: ['test'],
contentTemplates: {
titles: ['test'],
shortDescription: 'test',
problemStatement: 'test',
solutionPreview: 'test',
callToAction: {
primary: 'test',
secondary: 'test',
valueHook: 'test',
},
keyBenefits: ['test'],
socialProofPlan: ['test'],
engagementHooks: ['test'],
},
platformSpecific: [
{
platform: 'test',
contentFormat: 'test',
bestTiming: 'test',
communityRules: ['test'],
engagementStrategy: 'test',
},
],
}
)
})

it('should set testing plan when not already set', () => {
idea.setTestingPlan(testingPlan)
expect(idea.getTestingPlan()).toBe(testingPlan)
})

it('should throw error when testing plan is already set', () => {
idea.setTestingPlan(testingPlan)
expect(() => idea.setTestingPlan(testingPlan)).toThrow(
'TestingPlan already set'
)
})
})
})
Loading

0 comments on commit 070b28c

Please sign in to comment.