Taking advantage of the fact that:
When unmerged, they should have no column names in common.
Check if any of the column names in df2 exist in df. To do so, you can utilize the "columns" property of the DataFrame.
For example:
# Create DataFrames with respectively unique columns
df = pd.DataFrame([1,2,3], columns=['a'])
df2 = pd.DataFrame([4,5,6], columns=['b'])
# False; the DataFrames have not been mereged
not df.columns.intersection(df2.columns).empty
# Merge
df = df.merge(df2,how='left',left_index=True,right_index=True)
# True; the DataFrames have been merged
not df.columns.intersection(df2.columns).empty
Update: Suggestion comes from the comments. See similar options here: python: check if an numpy array contains any element of another array