Merge -r 1396971:1396972 from trunk to branch-2. Fixes: YARN-146. Add unit tests for computing fair share in the fair scheduler. Contributed by Sandy Ryza.