Lubricant analysis is a commonly available service. It's normally done on lubricating oil for large engines (heavy trucks, locomotives, ships) as a diagnostic tool. The usual tests are mostly to see what properties of the oil or engine are degrading. Full analysis of new oil to validate that it conforms to specification is available.[1]
Hydrocarbons are rather well studied.