function TestSession.calculateTotals(o)local T=o.results T.successCount=0 T.failureCount=0 T.skippedCount=0 T:visitAllNodes(function(o)local u=o.status local z=o.planNode.type if z==TestEnum.NodeType.It then if u==TestEnum.TestStatus.Success then T.successCount=T.successCount+1 elseif u==TestEnum.TestStatus.Failure then T.failureCount=T.failureCount+1 elseif u==TestEnum.TestStatus.Skipped then T.skippedCount=T.skippedCount+1 end end end)end
--[[
	Calculate success, failure, and skipped test counts in the tree at the
	current point in the execution.
]]
function TestSession:calculateTotals()
	local results = self.results

	results.successCount = 0
	results.failureCount = 0
	results.skippedCount = 0

	results:visitAllNodes(function(node)
		local status = node.status
		local nodeType = node.planNode.type

		if nodeType == TestEnum.NodeType.It then
			if status == TestEnum.TestStatus.Success then
				results.successCount = results.successCount + 1
			elseif status == TestEnum.TestStatus.Failure then
				results.failureCount = results.failureCount + 1
			elseif status == TestEnum.TestStatus.Skipped then
				results.skippedCount = results.skippedCount + 1
			end
		end
	end)
end
