def save_expectation_suite(self, filepath=None, discard_failed_expectations=True, discard_result_format_kwargs=True, discard_include_config_kwargs=True, discard_catch_exceptions_kwargs=True, suppress_warnings=False):
    "Writes ``_expectation_config`` to a JSON file.\n\n           Writes the DataAsset's expectation config to the specified JSON ``filepath``. Failing expectations            can be excluded from the JSON expectations config with ``discard_failed_expectations``. The kwarg key-value            pairs :ref:`result_format`, :ref:`include_config`, and :ref:`catch_exceptions` are optionally excluded from            the JSON expectations config.\n\n           Args:\n               filepath (string):                    The location and name to write the JSON config file to.\n               discard_failed_expectations (boolean):                    If True, excludes expectations that do not return ``success = True``.                    If False, all expectations are written to the JSON config file.\n               discard_result_format_kwargs (boolean):                    If True, the :ref:`result_format` attribute for each expectation is not written to the JSON config                    file.\n               discard_include_config_kwargs (boolean):                    If True, the :ref:`include_config` attribute for each expectation is not written to the JSON config                    file.\n               discard_catch_exceptions_kwargs (boolean):                    If True, the :ref:`catch_exceptions` attribute for each expectation is not written to the JSON                    config file.\n               suppress_warnings (boolean):                   It True, all warnings raised by Great Expectations, as a result of dropped expectations, are                   suppressed.\n\n        "
    expectation_suite = self.get_expectation_suite(discard_failed_expectations, discard_result_format_kwargs, discard_include_config_kwargs, discard_catch_exceptions_kwargs, suppress_warnings)
    if ((filepath is None) and (self._data_context is not None)):
        self._data_context.save_expectation_suite(expectation_suite)
    elif (filepath is not None):
        with open(filepath, 'w') as outfile:
            json.dump(expectationSuiteSchema.dump(expectation_suite), outfile, indent=2, sort_keys=True)
    else:
        raise ValueError('Unable to save config: filepath or data_context must be available.')
Writes ``_expectation_config`` to a JSON file.

Writes the DataAsset's expectation config to the specified JSON ``filepath``. Failing expectations            can be excluded from the JSON expectations config with ``discard_failed_expectations``. The kwarg key-value            pairs :ref:`result_format`, :ref:`include_config`, and :ref:`catch_exceptions` are optionally excluded from            the JSON expectations config.

Args:
    filepath (string):                    The location and name to write the JSON config file to.
    discard_failed_expectations (boolean):                    If True, excludes expectations that do not return ``success = True``.                    If False, all expectations are written to the JSON config file.
    discard_result_format_kwargs (boolean):                    If True, the :ref:`result_format` attribute for each expectation is not written to the JSON config                    file.
    discard_include_config_kwargs (boolean):                    If True, the :ref:`include_config` attribute for each expectation is not written to the JSON config                    file.
    discard_catch_exceptions_kwargs (boolean):                    If True, the :ref:`catch_exceptions` attribute for each expectation is not written to the JSON                    config file.
    suppress_warnings (boolean):                   It True, all warnings raised by Great Expectations, as a result of dropped expectations, are                   suppressed.
def save_expectation_suite(self, filepath=None, discard_failed_expectations=True, discard_result_format_kwargs=True, discard_include_config_kwargs=True, discard_catch_exceptions_kwargs=True, suppress_warnings=False):
    "Writes ``_expectation_config`` to a JSON file.\n\n           Writes the DataAsset's expectation config to the specified JSON ``filepath``. Failing expectations            can be excluded from the JSON expectations config with ``discard_failed_expectations``. The kwarg key-value            pairs :ref:`result_format`, :ref:`include_config`, and :ref:`catch_exceptions` are optionally excluded from            the JSON expectations config.\n\n           Args:\n               filepath (string):                    The location and name to write the JSON config file to.\n               discard_failed_expectations (boolean):                    If True, excludes expectations that do not return ``success = True``.                    If False, all expectations are written to the JSON config file.\n               discard_result_format_kwargs (boolean):                    If True, the :ref:`result_format` attribute for each expectation is not written to the JSON config                    file.\n               discard_include_config_kwargs (boolean):                    If True, the :ref:`include_config` attribute for each expectation is not written to the JSON config                    file.\n               discard_catch_exceptions_kwargs (boolean):                    If True, the :ref:`catch_exceptions` attribute for each expectation is not written to the JSON                    config file.\n               suppress_warnings (boolean):                   It True, all warnings raised by Great Expectations, as a result of dropped expectations, are                   suppressed.\n\n        "
    expectation_suite = self.get_expectation_suite(discard_failed_expectations, discard_result_format_kwargs, discard_include_config_kwargs, discard_catch_exceptions_kwargs, suppress_warnings)
    if ((filepath is None) and (self._data_context is not None)):
        self._data_context.save_expectation_suite(expectation_suite)
    elif (filepath is not None):
        with open(filepath, 'w') as outfile:
            json.dump(expectationSuiteSchema.dump(expectation_suite), outfile, indent=2, sort_keys=True)
    else:
        raise ValueError('Unable to save config: filepath or data_context must be available.')