input: Write a python function to connect to a MySQL database, fetch data from a specified table, convert it into a DataFrame, and plot a scatter plot of 'age' vs 'salary'.
  assert isinstance(fetch_and_plot('localhost', 'username', 'password', 'my_db', 'my_table'), pd.DataFrame)
  assert list(fetch_and_plot('localhost', 'username', 'password', 'my_db', 'my_table').columns) == ['id', 'name', 'occupation', 'age', 'salary', 'dob']
output: import pandas as pd
  import mysql.connector
  import matplotlib.pyplot as plt
  
  def fetch_and_plot(host, user, password, database, table):
      # Connect to the MySQL database
      connection = mysql.connector.connect(
          host=host,
          user=user,
          password=password,
          database=database
      )
      
      # Fetch data from the specified table
      query = f"SELECT * FROM {table}"
      df = pd.read_sql(query, connection)
      
      # Close the connection
      connection.close()
      
      # Plotting the scatter plot of 'age' vs 'salary'
      plt.scatter(df['age'], df['salary'])
      plt.xlabel('Age')
      plt.ylabel('Salary')
      plt.title('Scatter plot of Age vs Salary')
      plt.show()
      
      return df