I dont want to use the IDE
To be perfectly frank, I can take it or leave it. I mean, I think it's "OK" for small stuff, but I like complete control for "real" projects. See Footnote. I tend to do everything from a command line. (How 20th century is that? And not even late 20th century, right?)
unit test the code---
A very sound methodology!
...include the specific files into the Arduino library path,....
In the Arduino IDE, hold down the 'Shift' key when you compile a sketch. (In Arduino, you click on what is---inexplicably---called the "Verify" button. The one on the left.)
You can see all of the command line switches and sequence of steps that Arduino uses to create a library from the core function files and link it in with the .cpp file that Arduino creates from your .pde file. You can use that as the basis of your Makefile. By examining the files in the temporary directory that Arduino creates, you can also see how Arduino makes a real .cpp file from your sketch.
I do this for projects on my Linux system (Centos 5.5). I also create an "upload" target in the Makefile that calls avrdude.
Actually I have an "upload_tty" target that uses /dev/ttyS0 and and an "upload_usb" target that uses /dev/ttyUSB0, since sometimes I connect the Arduino board to the serial port and sometimes to USB. I set the default to USB, since that's my usual connection, but that can be overriden from the command line when I invoke the "make" program.
For me, I find that the ability to use the command-line options "-Wall -W -Werror" that support (enforce, actually) my self-imposed requirement for a completely clean compile (for my own stuff) has helped reduce debugging time. The goal of the Arduino team to keep people from having to learn "everything" about C++ is admirable, and it gets lots of people started without actually learning (much) C++, but I like the option to break away when I feel like it.
I never change anything about Arduino IDE or its library files. That way I can go back to the IDE for testing if I suspect that I didn't "do it right" when I abstracted the Arduino stuff into my external build process.
Also, it mans that I can compare results with things that I see on this forum from the mainly "pure Arduino" users. I learn a lot from seeing other people's approach to problem solving and I like to be able to reproduce their results---or not.
Control. Complete control.
I like to pretend that I am in control. I'm funny that way.