Inflation in scale-invariant theories of gravity