I found something odd in MMA 12.1 when symbolically integrating DiracDelta and Piecewise. These functions are integrated individually but not their sum. The following code
f[x_] = DiracDelta[x - 12.0];
Integrate[f[x], x]
g[x_] = Piecewise[{{2 x, x < 1}, {4 x, 1 <= x < 2}, {0, True}}];
Integrate[g[x], x]
Integrate[f[x] + g[x], x]
produces evaluated integrals in the first two cases but not in the third case. Why?
$$\theta (x-12.)$$
$$\begin{cases} x^2 & x\leq 1 \\ 2 x^2-1 & 1<x\leq 2 \\ 7 & \text{True} \\ \end{cases}$$
$$\int \left(\left( \begin{cases} 2 x & x<1 \\ 4 x & 1\leq x<2 \\ \end{cases} \right)+\delta (x-12.)\right) \, dx$$
By the way, symbolic Python works as expected.
from sympy import *
x=var('x')
f=DiracDelta(x)
g=Piecewise((1,x<3), (2,x<10),(0,True))
integrate(f+g,x)
Integrate[f[x], {x, a, b}, Assumptions -> {a < b}]
. $\endgroup$