Pilot flying C-152 aircraft reported entering Class B airspace without a clearance.
Synopsis
Pilot flying C-152 aircraft reported entering Class B airspace without a clearance.
Narrative
Night VFR flight ZZZ-ZZZ1. Prior to departure; coordinate with a fellow pilot to conduct a formation flight; breaking off near ZZZ2. Standard departure and cruising at 3;500 ft.; I coordinated a climb to 3;700 ft. due to the dark mountainous terrain. Shortly after arriving at VOR (ZZZ3); while in close formation; the second plane appeared to have bank sharply to the left (in my direction). I quickly executed a climb; and noted my altimeter indicated 4;100 feet; breaking the ZZZ4 class Bravo airspace floor of 4;000 ft. I communicated with the fellow pilot that I climbed and ask where he was. I made visual contact and then communicated a descent back to 3;500 ft. We terminated the formation and I contacted Approach immediately. They did not mention the incident. The remainder of the flight was uneventful. While on the ground I debriefed with the pilot and he stated that he had banked to the left and admitted to not communicating that. I reviewed my GPS tracking and it showed I did not surpass 3;934 ft. I believe I was just in my maneuvering to avoid a mid-air collision; although; formation in that environment was not a good decision.
Source: NASA Aviation Safety Reporting System (public domain). Reports are voluntary submissions and are not verified by NASA.