My solar system will shut off if the grid shuts off. The reason is to guarantee no voltage on the lines when the technician is looking to repair.
Having said that I have no battery, but if I did then probably it could just isolate the grid and stop feeding back when the grid shuts down and run the house off the battery.
You can't get true 100% coverage* on digital hardware. (on quantum maybe!) so what to test or not is always a judgement call. Most of the time I'd assume the software stack is trustworthy but if you are doing something extreme you may want to test the compiler or even formally prove the compiler works as expected.
* true as in all possible inputs and outputs rather than merely all code paths
Sure I'm thinking more of the case where there is a bug in the said program. Formal proofs and verification could help but attackers just need to find one weakness.
> At some point you have to assume something is there and correct
If you excel at compositional design then this may work OK but a lot of code bases I have worked on just need a good ol' refactor to sort the mess out. And then the "there and correct" part could fail due to human error, or the new person not knowing the old assumptions etc. The asserts are a step in the right direction in documenting the assumptions though. Types go one level better by both documenting the interface, and enforcing that contract at compile time.
> They need a much better idea of time (such as approaches to McCarthy's fluents).
I am not sure what the time problem is for functional programming, but I reckon the Elm language/framework solves problems with time in a very elegant way with it's flavour of FRP and Signals.
In Elm, you can play back your UI interactions in a debugger as they happened and watch the variables as they would have been!
If you want to see what people will be getting excited about in .NET in 5 years time, Java in 10 and Javascript in 15, just keep looking at Haskell. The stuff in this article is certainly not new but concurrency abstraction and implementation is miles ahead in Haskell.
A smart person who is also pragmatic and takes the team into account though is superproductive. Their solutions may take a bit of learning but it pays off.
The list will depend on the language, platform and your interests. Build something that interests you and challenges you a little but isn't too overwhelming.
This style of programming reminds me of SQL where you specify intent and let a query optimiser work out the execution plan. I like it. Not sure this is production ready but it'd be fun to try at work.
The compiler guarantees it won't happen. Such a test would be a test of the compiler and in my opinion unnecessary. And in Haskell at least... impossible. You can't write the the test because IT won't compile!