feature-branch-one-commit
branch
main + feat/x (1 commit ahead, src/feature.ts)
Description
Minimal feature-branch shape. `main` has one initial commit; `feat/x` is checked out with one commit on top adding `src/feature.ts`. The worktree is clean. Useful for testing: - `coco changelog --branch main` - `coco review --branch main` - any branch-vs-base diff flow - the changelog auto-body in the create-PR flow
Contracts
- main has 1 commit
- feat/x is checked out
- feat/x has 1 commit on top of main
- src/feature.ts exists
- worktree is clean
Tags
Branches
feat/xmain Use it
import { spinUpScenario } from '@gfargo/git-scenarios'
const repo = await spinUpScenario('feature-branch-one-commit') npx git-scenarios create feature-branch-one-commit import { describeWithScenario } from '@gfargo/git-scenarios/jest'
describeWithScenario('feature-branch-one-commit', (getRepo) => {
it('should have the expected state', async () => {
const repo = getRepo()
// your assertions here
})
}) Commit graph
* 7d4e915 (HEAD -> feat/x) feat: add feature module
* 26c2b1e (main) chore: initial commit