The it() function is defined by the jasmine testing framework, it is not part of angular per se. You’ll see it in angular’s documentation because they are encouraging you (for good reason) to get in the habit of writing tests for your code, and demonstrating how the code will work in a test.
The it() function defines a jasmine test. It is so named because its name makes reading tests almost like reading English. The second argument to the it() function is itself a function, that when executed will probably run some number of expect() functions. expect() functions are used to actually test the things you “expect” to be true.
Read more about jasmine testing on the jasmine framework’s website: http://jasmine.github.io/