	@Test
	public void testCreateFriendship_Regular() {

		// A follows: B, C, D, E
		this.algorithm.createFriendship(this.USER_A, this.USER_B);
		this.algorithm.createFriendship(this.USER_A, this.USER_C);
		this.algorithm.createFriendship(this.USER_A, this.USER_D);
		this.algorithm.createFriendship(this.USER_A, this.USER_E);

		// B follows: A, D
		this.algorithm.createFriendship(this.USER_B, this.USER_A);
		this.algorithm.createFriendship(this.USER_B, this.USER_D);

		// C follows: A, E
		this.algorithm.createFriendship(this.USER_C, this.USER_A);
		this.algorithm.createFriendship(this.USER_C, this.USER_E);

		// D follows: C
		this.algorithm.createFriendship(this.USER_D, this.USER_C);

		// E follows none

		// prepare for relationship count check
		final Map<Node, int[]> sortedCounts = new HashMap<Node, int[]>();

		// A: 4 out, 2 in
		sortedCounts.put(this.USER_A, new int[] { 4, 2 });
		// B: 2 out, 1 in
		sortedCounts.put(this.USER_B, new int[] { 2, 1 });
		// C: 2 out, 2 in
		sortedCounts.put(this.USER_C, new int[] { 2, 2 });
		// D: 1 out, 2 in
		sortedCounts.put(this.USER_D, new int[] { 1, 2 });
		// E: 0 out, 2 in
		sortedCounts.put(this.USER_E, new int[] { 0, 2 });

		// check number of relationships for each user
		int[] relationshipCount;
		for (Node user : AlgorithmTests.USERS) {
			relationshipCount = sortedCounts.get(user);

			// ego type: 1 (or 0 if not following any users)
			assertEquals(getNumberOfRelationships(user.getRelationships(
					SocialGraphRelationshipType.GRAPHITY, Direction.OUTGOING)),
					(relationshipCount[0] != 0) ? 1 : 0);

			// assume matching relationship counts
			assertEquals(getNumberOfRelationships(user.getRelationships(
					SocialGraphRelationshipType.FOLLOW, Direction.OUTGOING)),
					relationshipCount[0]);
			assertEquals(getNumberOfRelationships(user.getRelationships(
					SocialGraphRelationshipType.REPLICA, Direction.INCOMING)),
					relationshipCount[1]);
		}

		this.transaction.success();
	}