This is absolutely something that happened often enough to be notable. Although the ammunition would not be interchangeable between American and German rifles, making resupply a considerable issue, the Germans in World War II had a certain habit of scavenging just about anything they could capture and by the end of the war they had collectively captured millions of rifles from everyone they fought and ultimately lost to. In typical German fashion, nearly every foreign piece of equipment captured intact got its own designation.
For instance, the M1 Garand received the designation “Selbstladegewehr 251(a)” while the M1 Carbine received the designation “Selbstladekarabiner 455(a)” with the (a) part of the designation in both cases denoting America as the country of origin. In additions to small arms, captured foreign tanks were extensively used throughout the war and captured foreign artillery saw considerable deployment along the Atlantic Wall, the coastal fortifications which ran from Norway to the Franco-Spanish border.
There are many photographs of Germans with captured allied weapons; some are even colorized.
Seen above are numerous Garand rifles and Thompson submachineguns. Seen below is an M1 Carbine.
Seen below is a captured Soviet SVT-40.