Test commit and mouse event