This is a very generic procedure outlined here, but it will give you some idea of the work flow if you're a developer in an XP environment. Customer lists the features that the software must provide. Programmers break the features into stand-alone tasks and estimate the work needed to complete each task. Customer chooses the most important tasks that can be completed by the next release. Programmers choose tasks, and work in pairs.
Programmers write unit tests.
Programmers add features to pass unit tests. Programmers integrate code. Programmers produce a released version. Customer runs acceptance tests. Version goes into production.