 			
 			assertThat(registry, array(cmd1, cmd3, cmd2));
 		}
+		
+		
+		[Test]
+		public function commands_executed_before_mediator_get_notificaion():void
+		{
+			const registry:Array = [];
+			
+			const command:Command = new RegistryCommand("cmd");
+			const mediator:Mediator = new RegistryMediator(registry);
+			mediator.subscribe(notification);
+			
+			facade.addMediator(mediator);
+			facade.addCommand(notification, command);
+			
+			facade.sendNotification(notification, registry);
+			
+			assertThat(registry, array(command, mediator));
+		}
 	}
 }
 
+import ru.whitered.kote.NotificationObject;
+import ru.whitered.kote.Mediator;
 import ru.whitered.kote.Command;
 
 
 
 
-class CustomCommand extends Command
+class RegistryCommand extends Command
 {
 	private var name:String;
 	
 	
 	
-	public function CustomCommand(name:String) 
+	public function RegistryCommand(name:String) 
 	{
 		this.name = name;
 	}

		return name;
	}
}

		[Test]
		public function commands_with_same_priority_are_executed_consecutively():void
		{
			const cmd1:Command = new RegistryCommand("cmd 1");
			const cmd2:Command = new RegistryCommand("cmd 2");
			const cmd3:Command = new RegistryCommand("cmd 3");
			
			facade.addCommand(notification, cmd1);
			facade.addCommand(notification, cmd2);
