// Code generated by azure-service-operator-codegen. DO NOT EDIT.
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT license.
package arm

import (
	"encoding/json"
	"github.com/google/go-cmp/cmp"
	"github.com/google/go-cmp/cmp/cmpopts"
	"github.com/kr/pretty"
	"github.com/kylelemons/godebug/diff"
	"github.com/leanovate/gopter"
	"github.com/leanovate/gopter/gen"
	"github.com/leanovate/gopter/prop"
	"os"
	"reflect"
	"testing"
)

func Test_ApplicationGateway_STATUS_ApplicationGatewayWebApplicationFirewallPolicy_SubResourceEmbedded_WhenSerializedToJson_DeserializesAsEqual(t *testing.T) {
	t.Parallel()
	parameters := gopter.DefaultTestParameters()
	parameters.MinSuccessfulTests = 80
	parameters.MaxSize = 3
	properties := gopter.NewProperties(parameters)
	properties.Property(
		"Round trip of ApplicationGateway_STATUS_ApplicationGatewayWebApplicationFirewallPolicy_SubResourceEmbedded via JSON returns original",
		prop.ForAll(RunJSONSerializationTestForApplicationGateway_STATUS_ApplicationGatewayWebApplicationFirewallPolicy_SubResourceEmbedded, ApplicationGateway_STATUS_ApplicationGatewayWebApplicationFirewallPolicy_SubResourceEmbeddedGenerator()))
	properties.TestingRun(t, gopter.NewFormatedReporter(true, 240, os.Stdout))
}

// RunJSONSerializationTestForApplicationGateway_STATUS_ApplicationGatewayWebApplicationFirewallPolicy_SubResourceEmbedded runs a test to see if a specific instance of ApplicationGateway_STATUS_ApplicationGatewayWebApplicationFirewallPolicy_SubResourceEmbedded round trips to JSON and back losslessly
func RunJSONSerializationTestForApplicationGateway_STATUS_ApplicationGatewayWebApplicationFirewallPolicy_SubResourceEmbedded(subject ApplicationGateway_STATUS_ApplicationGatewayWebApplicationFirewallPolicy_SubResourceEmbedded) string {
	// Serialize to JSON
	bin, err := json.Marshal(subject)
	if err != nil {
		return err.Error()
	}

	// Deserialize back into memory
	var actual ApplicationGateway_STATUS_ApplicationGatewayWebApplicationFirewallPolicy_SubResourceEmbedded
	err = json.Unmarshal(bin, &actual)
	if err != nil {
		return err.Error()
	}

	// Check for outcome
	match := cmp.Equal(subject, actual, cmpopts.EquateEmpty())
	if !match {
		actualFmt := pretty.Sprint(actual)
		subjectFmt := pretty.Sprint(subject)
		result := diff.Diff(subjectFmt, actualFmt)
		return result
	}

	return ""
}

// Generator of ApplicationGateway_STATUS_ApplicationGatewayWebApplicationFirewallPolicy_SubResourceEmbedded instances
// for property testing - lazily instantiated by
// ApplicationGateway_STATUS_ApplicationGatewayWebApplicationFirewallPolicy_SubResourceEmbeddedGenerator()
var applicationGateway_STATUS_ApplicationGatewayWebApplicationFirewallPolicy_SubResourceEmbeddedGenerator gopter.Gen

// ApplicationGateway_STATUS_ApplicationGatewayWebApplicationFirewallPolicy_SubResourceEmbeddedGenerator returns a generator of ApplicationGateway_STATUS_ApplicationGatewayWebApplicationFirewallPolicy_SubResourceEmbedded instances for property testing.
func ApplicationGateway_STATUS_ApplicationGatewayWebApplicationFirewallPolicy_SubResourceEmbeddedGenerator() gopter.Gen {
	if applicationGateway_STATUS_ApplicationGatewayWebApplicationFirewallPolicy_SubResourceEmbeddedGenerator != nil {
		return applicationGateway_STATUS_ApplicationGatewayWebApplicationFirewallPolicy_SubResourceEmbeddedGenerator
	}

	generators := make(map[string]gopter.Gen)
	AddIndependentPropertyGeneratorsForApplicationGateway_STATUS_ApplicationGatewayWebApplicationFirewallPolicy_SubResourceEmbedded(generators)
	applicationGateway_STATUS_ApplicationGatewayWebApplicationFirewallPolicy_SubResourceEmbeddedGenerator = gen.Struct(reflect.TypeOf(ApplicationGateway_STATUS_ApplicationGatewayWebApplicationFirewallPolicy_SubResourceEmbedded{}), generators)

	return applicationGateway_STATUS_ApplicationGatewayWebApplicationFirewallPolicy_SubResourceEmbeddedGenerator
}

// AddIndependentPropertyGeneratorsForApplicationGateway_STATUS_ApplicationGatewayWebApplicationFirewallPolicy_SubResourceEmbedded is a factory method for creating gopter generators
func AddIndependentPropertyGeneratorsForApplicationGateway_STATUS_ApplicationGatewayWebApplicationFirewallPolicy_SubResourceEmbedded(gens map[string]gopter.Gen) {
	gens["Id"] = gen.PtrOf(gen.AlphaString())
}

func Test_ExclusionManagedRuleGroup_STATUS_WhenSerializedToJson_DeserializesAsEqual(t *testing.T) {
	t.Parallel()
	parameters := gopter.DefaultTestParameters()
	parameters.MinSuccessfulTests = 80
	parameters.MaxSize = 3
	properties := gopter.NewProperties(parameters)
	properties.Property(
		"Round trip of ExclusionManagedRuleGroup_STATUS via JSON returns original",
		prop.ForAll(RunJSONSerializationTestForExclusionManagedRuleGroup_STATUS, ExclusionManagedRuleGroup_STATUSGenerator()))
	properties.TestingRun(t, gopter.NewFormatedReporter(true, 240, os.Stdout))
}

// RunJSONSerializationTestForExclusionManagedRuleGroup_STATUS runs a test to see if a specific instance of ExclusionManagedRuleGroup_STATUS round trips to JSON and back losslessly
func RunJSONSerializationTestForExclusionManagedRuleGroup_STATUS(subject ExclusionManagedRuleGroup_STATUS) string {
	// Serialize to JSON
	bin, err := json.Marshal(subject)
	if err != nil {
		return err.Error()
	}

	// Deserialize back into memory
	var actual ExclusionManagedRuleGroup_STATUS
	err = json.Unmarshal(bin, &actual)
	if err != nil {
		return err.Error()
	}

	// Check for outcome
	match := cmp.Equal(subject, actual, cmpopts.EquateEmpty())
	if !match {
		actualFmt := pretty.Sprint(actual)
		subjectFmt := pretty.Sprint(subject)
		result := diff.Diff(subjectFmt, actualFmt)
		return result
	}

	return ""
}

// Generator of ExclusionManagedRuleGroup_STATUS instances for property testing - lazily instantiated by
// ExclusionManagedRuleGroup_STATUSGenerator()
var exclusionManagedRuleGroup_STATUSGenerator gopter.Gen

// ExclusionManagedRuleGroup_STATUSGenerator returns a generator of ExclusionManagedRuleGroup_STATUS instances for property testing.
// We first initialize exclusionManagedRuleGroup_STATUSGenerator with a simplified generator based on the
// fields with primitive types then replacing it with a more complex one that also handles complex fields
// to ensure any cycles in the object graph properly terminate.
func ExclusionManagedRuleGroup_STATUSGenerator() gopter.Gen {
	if exclusionManagedRuleGroup_STATUSGenerator != nil {
		return exclusionManagedRuleGroup_STATUSGenerator
	}

	generators := make(map[string]gopter.Gen)
	AddIndependentPropertyGeneratorsForExclusionManagedRuleGroup_STATUS(generators)
	exclusionManagedRuleGroup_STATUSGenerator = gen.Struct(reflect.TypeOf(ExclusionManagedRuleGroup_STATUS{}), generators)

	// The above call to gen.Struct() captures the map, so create a new one
	generators = make(map[string]gopter.Gen)
	AddIndependentPropertyGeneratorsForExclusionManagedRuleGroup_STATUS(generators)
	AddRelatedPropertyGeneratorsForExclusionManagedRuleGroup_STATUS(generators)
	exclusionManagedRuleGroup_STATUSGenerator = gen.Struct(reflect.TypeOf(ExclusionManagedRuleGroup_STATUS{}), generators)

	return exclusionManagedRuleGroup_STATUSGenerator
}

// AddIndependentPropertyGeneratorsForExclusionManagedRuleGroup_STATUS is a factory method for creating gopter generators
func AddIndependentPropertyGeneratorsForExclusionManagedRuleGroup_STATUS(gens map[string]gopter.Gen) {
	gens["RuleGroupName"] = gen.PtrOf(gen.AlphaString())
}

// AddRelatedPropertyGeneratorsForExclusionManagedRuleGroup_STATUS is a factory method for creating gopter generators
func AddRelatedPropertyGeneratorsForExclusionManagedRuleGroup_STATUS(gens map[string]gopter.Gen) {
	gens["Rules"] = gen.SliceOf(ExclusionManagedRule_STATUSGenerator())
}

func Test_ExclusionManagedRuleSet_STATUS_WhenSerializedToJson_DeserializesAsEqual(t *testing.T) {
	t.Parallel()
	parameters := gopter.DefaultTestParameters()
	parameters.MinSuccessfulTests = 80
	parameters.MaxSize = 3
	properties := gopter.NewProperties(parameters)
	properties.Property(
		"Round trip of ExclusionManagedRuleSet_STATUS via JSON returns original",
		prop.ForAll(RunJSONSerializationTestForExclusionManagedRuleSet_STATUS, ExclusionManagedRuleSet_STATUSGenerator()))
	properties.TestingRun(t, gopter.NewFormatedReporter(true, 240, os.Stdout))
}

// RunJSONSerializationTestForExclusionManagedRuleSet_STATUS runs a test to see if a specific instance of ExclusionManagedRuleSet_STATUS round trips to JSON and back losslessly
func RunJSONSerializationTestForExclusionManagedRuleSet_STATUS(subject ExclusionManagedRuleSet_STATUS) string {
	// Serialize to JSON
	bin, err := json.Marshal(subject)
	if err != nil {
		return err.Error()
	}

	// Deserialize back into memory
	var actual ExclusionManagedRuleSet_STATUS
	err = json.Unmarshal(bin, &actual)
	if err != nil {
		return err.Error()
	}

	// Check for outcome
	match := cmp.Equal(subject, actual, cmpopts.EquateEmpty())
	if !match {
		actualFmt := pretty.Sprint(actual)
		subjectFmt := pretty.Sprint(subject)
		result := diff.Diff(subjectFmt, actualFmt)
		return result
	}

	return ""
}

// Generator of ExclusionManagedRuleSet_STATUS instances for property testing - lazily instantiated by
// ExclusionManagedRuleSet_STATUSGenerator()
var exclusionManagedRuleSet_STATUSGenerator gopter.Gen

// ExclusionManagedRuleSet_STATUSGenerator returns a generator of ExclusionManagedRuleSet_STATUS instances for property testing.
// We first initialize exclusionManagedRuleSet_STATUSGenerator with a simplified generator based on the
// fields with primitive types then replacing it with a more complex one that also handles complex fields
// to ensure any cycles in the object graph properly terminate.
func ExclusionManagedRuleSet_STATUSGenerator() gopter.Gen {
	if exclusionManagedRuleSet_STATUSGenerator != nil {
		return exclusionManagedRuleSet_STATUSGenerator
	}

	generators := make(map[string]gopter.Gen)
	AddIndependentPropertyGeneratorsForExclusionManagedRuleSet_STATUS(generators)
	exclusionManagedRuleSet_STATUSGenerator = gen.Struct(reflect.TypeOf(ExclusionManagedRuleSet_STATUS{}), generators)

	// The above call to gen.Struct() captures the map, so create a new one
	generators = make(map[string]gopter.Gen)
	AddIndependentPropertyGeneratorsForExclusionManagedRuleSet_STATUS(generators)
	AddRelatedPropertyGeneratorsForExclusionManagedRuleSet_STATUS(generators)
	exclusionManagedRuleSet_STATUSGenerator = gen.Struct(reflect.TypeOf(ExclusionManagedRuleSet_STATUS{}), generators)

	return exclusionManagedRuleSet_STATUSGenerator
}

// AddIndependentPropertyGeneratorsForExclusionManagedRuleSet_STATUS is a factory method for creating gopter generators
func AddIndependentPropertyGeneratorsForExclusionManagedRuleSet_STATUS(gens map[string]gopter.Gen) {
	gens["RuleSetType"] = gen.PtrOf(gen.AlphaString())
	gens["RuleSetVersion"] = gen.PtrOf(gen.AlphaString())
}

// AddRelatedPropertyGeneratorsForExclusionManagedRuleSet_STATUS is a factory method for creating gopter generators
func AddRelatedPropertyGeneratorsForExclusionManagedRuleSet_STATUS(gens map[string]gopter.Gen) {
	gens["RuleGroups"] = gen.SliceOf(ExclusionManagedRuleGroup_STATUSGenerator())
}

func Test_ExclusionManagedRule_STATUS_WhenSerializedToJson_DeserializesAsEqual(t *testing.T) {
	t.Parallel()
	parameters := gopter.DefaultTestParameters()
	parameters.MinSuccessfulTests = 80
	parameters.MaxSize = 3
	properties := gopter.NewProperties(parameters)
	properties.Property(
		"Round trip of ExclusionManagedRule_STATUS via JSON returns original",
		prop.ForAll(RunJSONSerializationTestForExclusionManagedRule_STATUS, ExclusionManagedRule_STATUSGenerator()))
	properties.TestingRun(t, gopter.NewFormatedReporter(true, 240, os.Stdout))
}

// RunJSONSerializationTestForExclusionManagedRule_STATUS runs a test to see if a specific instance of ExclusionManagedRule_STATUS round trips to JSON and back losslessly
func RunJSONSerializationTestForExclusionManagedRule_STATUS(subject ExclusionManagedRule_STATUS) string {
	// Serialize to JSON
	bin, err := json.Marshal(subject)
	if err != nil {
		return err.Error()
	}

	// Deserialize back into memory
	var actual ExclusionManagedRule_STATUS
	err = json.Unmarshal(bin, &actual)
	if err != nil {
		return err.Error()
	}

	// Check for outcome
	match := cmp.Equal(subject, actual, cmpopts.EquateEmpty())
	if !match {
		actualFmt := pretty.Sprint(actual)
		subjectFmt := pretty.Sprint(subject)
		result := diff.Diff(subjectFmt, actualFmt)
		return result
	}

	return ""
}

// Generator of ExclusionManagedRule_STATUS instances for property testing - lazily instantiated by
// ExclusionManagedRule_STATUSGenerator()
var exclusionManagedRule_STATUSGenerator gopter.Gen

// ExclusionManagedRule_STATUSGenerator returns a generator of ExclusionManagedRule_STATUS instances for property testing.
func ExclusionManagedRule_STATUSGenerator() gopter.Gen {
	if exclusionManagedRule_STATUSGenerator != nil {
		return exclusionManagedRule_STATUSGenerator
	}

	generators := make(map[string]gopter.Gen)
	AddIndependentPropertyGeneratorsForExclusionManagedRule_STATUS(generators)
	exclusionManagedRule_STATUSGenerator = gen.Struct(reflect.TypeOf(ExclusionManagedRule_STATUS{}), generators)

	return exclusionManagedRule_STATUSGenerator
}

// AddIndependentPropertyGeneratorsForExclusionManagedRule_STATUS is a factory method for creating gopter generators
func AddIndependentPropertyGeneratorsForExclusionManagedRule_STATUS(gens map[string]gopter.Gen) {
	gens["RuleId"] = gen.PtrOf(gen.AlphaString())
}

func Test_GroupByUserSession_STATUS_WhenSerializedToJson_DeserializesAsEqual(t *testing.T) {
	t.Parallel()
	parameters := gopter.DefaultTestParameters()
	parameters.MinSuccessfulTests = 80
	parameters.MaxSize = 3
	properties := gopter.NewProperties(parameters)
	properties.Property(
		"Round trip of GroupByUserSession_STATUS via JSON returns original",
		prop.ForAll(RunJSONSerializationTestForGroupByUserSession_STATUS, GroupByUserSession_STATUSGenerator()))
	properties.TestingRun(t, gopter.NewFormatedReporter(true, 240, os.Stdout))
}

// RunJSONSerializationTestForGroupByUserSession_STATUS runs a test to see if a specific instance of GroupByUserSession_STATUS round trips to JSON and back losslessly
func RunJSONSerializationTestForGroupByUserSession_STATUS(subject GroupByUserSession_STATUS) string {
	// Serialize to JSON
	bin, err := json.Marshal(subject)
	if err != nil {
		return err.Error()
	}

	// Deserialize back into memory
	var actual GroupByUserSession_STATUS
	err = json.Unmarshal(bin, &actual)
	if err != nil {
		return err.Error()
	}

	// Check for outcome
	match := cmp.Equal(subject, actual, cmpopts.EquateEmpty())
	if !match {
		actualFmt := pretty.Sprint(actual)
		subjectFmt := pretty.Sprint(subject)
		result := diff.Diff(subjectFmt, actualFmt)
		return result
	}

	return ""
}

// Generator of GroupByUserSession_STATUS instances for property testing - lazily instantiated by
// GroupByUserSession_STATUSGenerator()
var groupByUserSession_STATUSGenerator gopter.Gen

// GroupByUserSession_STATUSGenerator returns a generator of GroupByUserSession_STATUS instances for property testing.
func GroupByUserSession_STATUSGenerator() gopter.Gen {
	if groupByUserSession_STATUSGenerator != nil {
		return groupByUserSession_STATUSGenerator
	}

	generators := make(map[string]gopter.Gen)
	AddRelatedPropertyGeneratorsForGroupByUserSession_STATUS(generators)
	groupByUserSession_STATUSGenerator = gen.Struct(reflect.TypeOf(GroupByUserSession_STATUS{}), generators)

	return groupByUserSession_STATUSGenerator
}

// AddRelatedPropertyGeneratorsForGroupByUserSession_STATUS is a factory method for creating gopter generators
func AddRelatedPropertyGeneratorsForGroupByUserSession_STATUS(gens map[string]gopter.Gen) {
	gens["GroupByVariables"] = gen.SliceOf(GroupByVariable_STATUSGenerator())
}

func Test_GroupByVariable_STATUS_WhenSerializedToJson_DeserializesAsEqual(t *testing.T) {
	t.Parallel()
	parameters := gopter.DefaultTestParameters()
	parameters.MinSuccessfulTests = 80
	parameters.MaxSize = 3
	properties := gopter.NewProperties(parameters)
	properties.Property(
		"Round trip of GroupByVariable_STATUS via JSON returns original",
		prop.ForAll(RunJSONSerializationTestForGroupByVariable_STATUS, GroupByVariable_STATUSGenerator()))
	properties.TestingRun(t, gopter.NewFormatedReporter(true, 240, os.Stdout))
}

// RunJSONSerializationTestForGroupByVariable_STATUS runs a test to see if a specific instance of GroupByVariable_STATUS round trips to JSON and back losslessly
func RunJSONSerializationTestForGroupByVariable_STATUS(subject GroupByVariable_STATUS) string {
	// Serialize to JSON
	bin, err := json.Marshal(subject)
	if err != nil {
		return err.Error()
	}

	// Deserialize back into memory
	var actual GroupByVariable_STATUS
	err = json.Unmarshal(bin, &actual)
	if err != nil {
		return err.Error()
	}

	// Check for outcome
	match := cmp.Equal(subject, actual, cmpopts.EquateEmpty())
	if !match {
		actualFmt := pretty.Sprint(actual)
		subjectFmt := pretty.Sprint(subject)
		result := diff.Diff(subjectFmt, actualFmt)
		return result
	}

	return ""
}

// Generator of GroupByVariable_STATUS instances for property testing - lazily instantiated by
// GroupByVariable_STATUSGenerator()
var groupByVariable_STATUSGenerator gopter.Gen

// GroupByVariable_STATUSGenerator returns a generator of GroupByVariable_STATUS instances for property testing.
func GroupByVariable_STATUSGenerator() gopter.Gen {
	if groupByVariable_STATUSGenerator != nil {
		return groupByVariable_STATUSGenerator
	}

	generators := make(map[string]gopter.Gen)
	AddIndependentPropertyGeneratorsForGroupByVariable_STATUS(generators)
	groupByVariable_STATUSGenerator = gen.Struct(reflect.TypeOf(GroupByVariable_STATUS{}), generators)

	return groupByVariable_STATUSGenerator
}

// AddIndependentPropertyGeneratorsForGroupByVariable_STATUS is a factory method for creating gopter generators
func AddIndependentPropertyGeneratorsForGroupByVariable_STATUS(gens map[string]gopter.Gen) {
	gens["VariableName"] = gen.PtrOf(gen.OneConstOf(GroupByVariable_VariableName_STATUS_ClientAddr, GroupByVariable_VariableName_STATUS_GeoLocation, GroupByVariable_VariableName_STATUS_None))
}

func Test_ManagedRuleGroupOverride_STATUS_WhenSerializedToJson_DeserializesAsEqual(t *testing.T) {
	t.Parallel()
	parameters := gopter.DefaultTestParameters()
	parameters.MinSuccessfulTests = 80
	parameters.MaxSize = 3
	properties := gopter.NewProperties(parameters)
	properties.Property(
		"Round trip of ManagedRuleGroupOverride_STATUS via JSON returns original",
		prop.ForAll(RunJSONSerializationTestForManagedRuleGroupOverride_STATUS, ManagedRuleGroupOverride_STATUSGenerator()))
	properties.TestingRun(t, gopter.NewFormatedReporter(true, 240, os.Stdout))
}

// RunJSONSerializationTestForManagedRuleGroupOverride_STATUS runs a test to see if a specific instance of ManagedRuleGroupOverride_STATUS round trips to JSON and back losslessly
func RunJSONSerializationTestForManagedRuleGroupOverride_STATUS(subject ManagedRuleGroupOverride_STATUS) string {
	// Serialize to JSON
	bin, err := json.Marshal(subject)
	if err != nil {
		return err.Error()
	}

	// Deserialize back into memory
	var actual ManagedRuleGroupOverride_STATUS
	err = json.Unmarshal(bin, &actual)
	if err != nil {
		return err.Error()
	}

	// Check for outcome
	match := cmp.Equal(subject, actual, cmpopts.EquateEmpty())
	if !match {
		actualFmt := pretty.Sprint(actual)
		subjectFmt := pretty.Sprint(subject)
		result := diff.Diff(subjectFmt, actualFmt)
		return result
	}

	return ""
}

// Generator of ManagedRuleGroupOverride_STATUS instances for property testing - lazily instantiated by
// ManagedRuleGroupOverride_STATUSGenerator()
var managedRuleGroupOverride_STATUSGenerator gopter.Gen

// ManagedRuleGroupOverride_STATUSGenerator returns a generator of ManagedRuleGroupOverride_STATUS instances for property testing.
// We first initialize managedRuleGroupOverride_STATUSGenerator with a simplified generator based on the
// fields with primitive types then replacing it with a more complex one that also handles complex fields
// to ensure any cycles in the object graph properly terminate.
func ManagedRuleGroupOverride_STATUSGenerator() gopter.Gen {
	if managedRuleGroupOverride_STATUSGenerator != nil {
		return managedRuleGroupOverride_STATUSGenerator
	}

	generators := make(map[string]gopter.Gen)
	AddIndependentPropertyGeneratorsForManagedRuleGroupOverride_STATUS(generators)
	managedRuleGroupOverride_STATUSGenerator = gen.Struct(reflect.TypeOf(ManagedRuleGroupOverride_STATUS{}), generators)

	// The above call to gen.Struct() captures the map, so create a new one
	generators = make(map[string]gopter.Gen)
	AddIndependentPropertyGeneratorsForManagedRuleGroupOverride_STATUS(generators)
	AddRelatedPropertyGeneratorsForManagedRuleGroupOverride_STATUS(generators)
	managedRuleGroupOverride_STATUSGenerator = gen.Struct(reflect.TypeOf(ManagedRuleGroupOverride_STATUS{}), generators)

	return managedRuleGroupOverride_STATUSGenerator
}

// AddIndependentPropertyGeneratorsForManagedRuleGroupOverride_STATUS is a factory method for creating gopter generators
func AddIndependentPropertyGeneratorsForManagedRuleGroupOverride_STATUS(gens map[string]gopter.Gen) {
	gens["RuleGroupName"] = gen.PtrOf(gen.AlphaString())
}

// AddRelatedPropertyGeneratorsForManagedRuleGroupOverride_STATUS is a factory method for creating gopter generators
func AddRelatedPropertyGeneratorsForManagedRuleGroupOverride_STATUS(gens map[string]gopter.Gen) {
	gens["Rules"] = gen.SliceOf(ManagedRuleOverride_STATUSGenerator())
}

func Test_ManagedRuleOverride_STATUS_WhenSerializedToJson_DeserializesAsEqual(t *testing.T) {
	t.Parallel()
	parameters := gopter.DefaultTestParameters()
	parameters.MinSuccessfulTests = 80
	parameters.MaxSize = 3
	properties := gopter.NewProperties(parameters)
	properties.Property(
		"Round trip of ManagedRuleOverride_STATUS via JSON returns original",
		prop.ForAll(RunJSONSerializationTestForManagedRuleOverride_STATUS, ManagedRuleOverride_STATUSGenerator()))
	properties.TestingRun(t, gopter.NewFormatedReporter(true, 240, os.Stdout))
}

// RunJSONSerializationTestForManagedRuleOverride_STATUS runs a test to see if a specific instance of ManagedRuleOverride_STATUS round trips to JSON and back losslessly
func RunJSONSerializationTestForManagedRuleOverride_STATUS(subject ManagedRuleOverride_STATUS) string {
	// Serialize to JSON
	bin, err := json.Marshal(subject)
	if err != nil {
		return err.Error()
	}

	// Deserialize back into memory
	var actual ManagedRuleOverride_STATUS
	err = json.Unmarshal(bin, &actual)
	if err != nil {
		return err.Error()
	}

	// Check for outcome
	match := cmp.Equal(subject, actual, cmpopts.EquateEmpty())
	if !match {
		actualFmt := pretty.Sprint(actual)
		subjectFmt := pretty.Sprint(subject)
		result := diff.Diff(subjectFmt, actualFmt)
		return result
	}

	return ""
}

// Generator of ManagedRuleOverride_STATUS instances for property testing - lazily instantiated by
// ManagedRuleOverride_STATUSGenerator()
var managedRuleOverride_STATUSGenerator gopter.Gen

// ManagedRuleOverride_STATUSGenerator returns a generator of ManagedRuleOverride_STATUS instances for property testing.
func ManagedRuleOverride_STATUSGenerator() gopter.Gen {
	if managedRuleOverride_STATUSGenerator != nil {
		return managedRuleOverride_STATUSGenerator
	}

	generators := make(map[string]gopter.Gen)
	AddIndependentPropertyGeneratorsForManagedRuleOverride_STATUS(generators)
	managedRuleOverride_STATUSGenerator = gen.Struct(reflect.TypeOf(ManagedRuleOverride_STATUS{}), generators)

	return managedRuleOverride_STATUSGenerator
}

// AddIndependentPropertyGeneratorsForManagedRuleOverride_STATUS is a factory method for creating gopter generators
func AddIndependentPropertyGeneratorsForManagedRuleOverride_STATUS(gens map[string]gopter.Gen) {
	gens["Action"] = gen.PtrOf(gen.OneConstOf(
		ActionType_STATUS_Allow,
		ActionType_STATUS_AnomalyScoring,
		ActionType_STATUS_Block,
		ActionType_STATUS_JSChallenge,
		ActionType_STATUS_Log))
	gens["RuleId"] = gen.PtrOf(gen.AlphaString())
	gens["State"] = gen.PtrOf(gen.OneConstOf(ManagedRuleOverride_State_STATUS_Disabled, ManagedRuleOverride_State_STATUS_Enabled))
}

func Test_ManagedRuleSet_STATUS_WhenSerializedToJson_DeserializesAsEqual(t *testing.T) {
	t.Parallel()
	parameters := gopter.DefaultTestParameters()
	parameters.MinSuccessfulTests = 80
	parameters.MaxSize = 3
	properties := gopter.NewProperties(parameters)
	properties.Property(
		"Round trip of ManagedRuleSet_STATUS via JSON returns original",
		prop.ForAll(RunJSONSerializationTestForManagedRuleSet_STATUS, ManagedRuleSet_STATUSGenerator()))
	properties.TestingRun(t, gopter.NewFormatedReporter(true, 240, os.Stdout))
}

// RunJSONSerializationTestForManagedRuleSet_STATUS runs a test to see if a specific instance of ManagedRuleSet_STATUS round trips to JSON and back losslessly
func RunJSONSerializationTestForManagedRuleSet_STATUS(subject ManagedRuleSet_STATUS) string {
	// Serialize to JSON
	bin, err := json.Marshal(subject)
	if err != nil {
		return err.Error()
	}

	// Deserialize back into memory
	var actual ManagedRuleSet_STATUS
	err = json.Unmarshal(bin, &actual)
	if err != nil {
		return err.Error()
	}

	// Check for outcome
	match := cmp.Equal(subject, actual, cmpopts.EquateEmpty())
	if !match {
		actualFmt := pretty.Sprint(actual)
		subjectFmt := pretty.Sprint(subject)
		result := diff.Diff(subjectFmt, actualFmt)
		return result
	}

	return ""
}

// Generator of ManagedRuleSet_STATUS instances for property testing - lazily instantiated by
// ManagedRuleSet_STATUSGenerator()
var managedRuleSet_STATUSGenerator gopter.Gen

// ManagedRuleSet_STATUSGenerator returns a generator of ManagedRuleSet_STATUS instances for property testing.
// We first initialize managedRuleSet_STATUSGenerator with a simplified generator based on the
// fields with primitive types then replacing it with a more complex one that also handles complex fields
// to ensure any cycles in the object graph properly terminate.
func ManagedRuleSet_STATUSGenerator() gopter.Gen {
	if managedRuleSet_STATUSGenerator != nil {
		return managedRuleSet_STATUSGenerator
	}

	generators := make(map[string]gopter.Gen)
	AddIndependentPropertyGeneratorsForManagedRuleSet_STATUS(generators)
	managedRuleSet_STATUSGenerator = gen.Struct(reflect.TypeOf(ManagedRuleSet_STATUS{}), generators)

	// The above call to gen.Struct() captures the map, so create a new one
	generators = make(map[string]gopter.Gen)
	AddIndependentPropertyGeneratorsForManagedRuleSet_STATUS(generators)
	AddRelatedPropertyGeneratorsForManagedRuleSet_STATUS(generators)
	managedRuleSet_STATUSGenerator = gen.Struct(reflect.TypeOf(ManagedRuleSet_STATUS{}), generators)

	return managedRuleSet_STATUSGenerator
}

// AddIndependentPropertyGeneratorsForManagedRuleSet_STATUS is a factory method for creating gopter generators
func AddIndependentPropertyGeneratorsForManagedRuleSet_STATUS(gens map[string]gopter.Gen) {
	gens["RuleSetType"] = gen.PtrOf(gen.AlphaString())
	gens["RuleSetVersion"] = gen.PtrOf(gen.AlphaString())
}

// AddRelatedPropertyGeneratorsForManagedRuleSet_STATUS is a factory method for creating gopter generators
func AddRelatedPropertyGeneratorsForManagedRuleSet_STATUS(gens map[string]gopter.Gen) {
	gens["RuleGroupOverrides"] = gen.SliceOf(ManagedRuleGroupOverride_STATUSGenerator())
}

func Test_ManagedRulesDefinition_STATUS_WhenSerializedToJson_DeserializesAsEqual(t *testing.T) {
	t.Parallel()
	parameters := gopter.DefaultTestParameters()
	parameters.MinSuccessfulTests = 80
	parameters.MaxSize = 3
	properties := gopter.NewProperties(parameters)
	properties.Property(
		"Round trip of ManagedRulesDefinition_STATUS via JSON returns original",
		prop.ForAll(RunJSONSerializationTestForManagedRulesDefinition_STATUS, ManagedRulesDefinition_STATUSGenerator()))
	properties.TestingRun(t, gopter.NewFormatedReporter(true, 240, os.Stdout))
}

// RunJSONSerializationTestForManagedRulesDefinition_STATUS runs a test to see if a specific instance of ManagedRulesDefinition_STATUS round trips to JSON and back losslessly
func RunJSONSerializationTestForManagedRulesDefinition_STATUS(subject ManagedRulesDefinition_STATUS) string {
	// Serialize to JSON
	bin, err := json.Marshal(subject)
	if err != nil {
		return err.Error()
	}

	// Deserialize back into memory
	var actual ManagedRulesDefinition_STATUS
	err = json.Unmarshal(bin, &actual)
	if err != nil {
		return err.Error()
	}

	// Check for outcome
	match := cmp.Equal(subject, actual, cmpopts.EquateEmpty())
	if !match {
		actualFmt := pretty.Sprint(actual)
		subjectFmt := pretty.Sprint(subject)
		result := diff.Diff(subjectFmt, actualFmt)
		return result
	}

	return ""
}

// Generator of ManagedRulesDefinition_STATUS instances for property testing - lazily instantiated by
// ManagedRulesDefinition_STATUSGenerator()
var managedRulesDefinition_STATUSGenerator gopter.Gen

// ManagedRulesDefinition_STATUSGenerator returns a generator of ManagedRulesDefinition_STATUS instances for property testing.
func ManagedRulesDefinition_STATUSGenerator() gopter.Gen {
	if managedRulesDefinition_STATUSGenerator != nil {
		return managedRulesDefinition_STATUSGenerator
	}

	generators := make(map[string]gopter.Gen)
	AddRelatedPropertyGeneratorsForManagedRulesDefinition_STATUS(generators)
	managedRulesDefinition_STATUSGenerator = gen.Struct(reflect.TypeOf(ManagedRulesDefinition_STATUS{}), generators)

	return managedRulesDefinition_STATUSGenerator
}

// AddRelatedPropertyGeneratorsForManagedRulesDefinition_STATUS is a factory method for creating gopter generators
func AddRelatedPropertyGeneratorsForManagedRulesDefinition_STATUS(gens map[string]gopter.Gen) {
	gens["Exclusions"] = gen.SliceOf(OwaspCrsExclusionEntry_STATUSGenerator())
	gens["ManagedRuleSets"] = gen.SliceOf(ManagedRuleSet_STATUSGenerator())
}

func Test_MatchCondition_STATUS_WhenSerializedToJson_DeserializesAsEqual(t *testing.T) {
	t.Parallel()
	parameters := gopter.DefaultTestParameters()
	parameters.MinSuccessfulTests = 80
	parameters.MaxSize = 3
	properties := gopter.NewProperties(parameters)
	properties.Property(
		"Round trip of MatchCondition_STATUS via JSON returns original",
		prop.ForAll(RunJSONSerializationTestForMatchCondition_STATUS, MatchCondition_STATUSGenerator()))
	properties.TestingRun(t, gopter.NewFormatedReporter(true, 240, os.Stdout))
}

// RunJSONSerializationTestForMatchCondition_STATUS runs a test to see if a specific instance of MatchCondition_STATUS round trips to JSON and back losslessly
func RunJSONSerializationTestForMatchCondition_STATUS(subject MatchCondition_STATUS) string {
	// Serialize to JSON
	bin, err := json.Marshal(subject)
	if err != nil {
		return err.Error()
	}

	// Deserialize back into memory
	var actual MatchCondition_STATUS
	err = json.Unmarshal(bin, &actual)
	if err != nil {
		return err.Error()
	}

	// Check for outcome
	match := cmp.Equal(subject, actual, cmpopts.EquateEmpty())
	if !match {
		actualFmt := pretty.Sprint(actual)
		subjectFmt := pretty.Sprint(subject)
		result := diff.Diff(subjectFmt, actualFmt)
		return result
	}

	return ""
}

// Generator of MatchCondition_STATUS instances for property testing - lazily instantiated by
// MatchCondition_STATUSGenerator()
var matchCondition_STATUSGenerator gopter.Gen

// MatchCondition_STATUSGenerator returns a generator of MatchCondition_STATUS instances for property testing.
// We first initialize matchCondition_STATUSGenerator with a simplified generator based on the
// fields with primitive types then replacing it with a more complex one that also handles complex fields
// to ensure any cycles in the object graph properly terminate.
func MatchCondition_STATUSGenerator() gopter.Gen {
	if matchCondition_STATUSGenerator != nil {
		return matchCondition_STATUSGenerator
	}

	generators := make(map[string]gopter.Gen)
	AddIndependentPropertyGeneratorsForMatchCondition_STATUS(generators)
	matchCondition_STATUSGenerator = gen.Struct(reflect.TypeOf(MatchCondition_STATUS{}), generators)

	// The above call to gen.Struct() captures the map, so create a new one
	generators = make(map[string]gopter.Gen)
	AddIndependentPropertyGeneratorsForMatchCondition_STATUS(generators)
	AddRelatedPropertyGeneratorsForMatchCondition_STATUS(generators)
	matchCondition_STATUSGenerator = gen.Struct(reflect.TypeOf(MatchCondition_STATUS{}), generators)

	return matchCondition_STATUSGenerator
}

// AddIndependentPropertyGeneratorsForMatchCondition_STATUS is a factory method for creating gopter generators
func AddIndependentPropertyGeneratorsForMatchCondition_STATUS(gens map[string]gopter.Gen) {
	gens["MatchValues"] = gen.SliceOf(gen.AlphaString())
	gens["NegationConditon"] = gen.PtrOf(gen.Bool())
	gens["Operator"] = gen.PtrOf(gen.OneConstOf(
		MatchCondition_Operator_STATUS_Any,
		MatchCondition_Operator_STATUS_BeginsWith,
		MatchCondition_Operator_STATUS_Contains,
		MatchCondition_Operator_STATUS_EndsWith,
		MatchCondition_Operator_STATUS_Equal,
		MatchCondition_Operator_STATUS_GeoMatch,
		MatchCondition_Operator_STATUS_GreaterThan,
		MatchCondition_Operator_STATUS_GreaterThanOrEqual,
		MatchCondition_Operator_STATUS_IPMatch,
		MatchCondition_Operator_STATUS_LessThan,
		MatchCondition_Operator_STATUS_LessThanOrEqual,
		MatchCondition_Operator_STATUS_Regex))
	gens["Transforms"] = gen.SliceOf(gen.OneConstOf(
		Transform_STATUS_HtmlEntityDecode,
		Transform_STATUS_Lowercase,
		Transform_STATUS_RemoveNulls,
		Transform_STATUS_Trim,
		Transform_STATUS_Uppercase,
		Transform_STATUS_UrlDecode,
		Transform_STATUS_UrlEncode))
}

// AddRelatedPropertyGeneratorsForMatchCondition_STATUS is a factory method for creating gopter generators
func AddRelatedPropertyGeneratorsForMatchCondition_STATUS(gens map[string]gopter.Gen) {
	gens["MatchVariables"] = gen.SliceOf(MatchVariable_STATUSGenerator())
}

func Test_MatchVariable_STATUS_WhenSerializedToJson_DeserializesAsEqual(t *testing.T) {
	t.Parallel()
	parameters := gopter.DefaultTestParameters()
	parameters.MinSuccessfulTests = 80
	parameters.MaxSize = 3
	properties := gopter.NewProperties(parameters)
	properties.Property(
		"Round trip of MatchVariable_STATUS via JSON returns original",
		prop.ForAll(RunJSONSerializationTestForMatchVariable_STATUS, MatchVariable_STATUSGenerator()))
	properties.TestingRun(t, gopter.NewFormatedReporter(true, 240, os.Stdout))
}

// RunJSONSerializationTestForMatchVariable_STATUS runs a test to see if a specific instance of MatchVariable_STATUS round trips to JSON and back losslessly
func RunJSONSerializationTestForMatchVariable_STATUS(subject MatchVariable_STATUS) string {
	// Serialize to JSON
	bin, err := json.Marshal(subject)
	if err != nil {
		return err.Error()
	}

	// Deserialize back into memory
	var actual MatchVariable_STATUS
	err = json.Unmarshal(bin, &actual)
	if err != nil {
		return err.Error()
	}

	// Check for outcome
	match := cmp.Equal(subject, actual, cmpopts.EquateEmpty())
	if !match {
		actualFmt := pretty.Sprint(actual)
		subjectFmt := pretty.Sprint(subject)
		result := diff.Diff(subjectFmt, actualFmt)
		return result
	}

	return ""
}

// Generator of MatchVariable_STATUS instances for property testing - lazily instantiated by
// MatchVariable_STATUSGenerator()
var matchVariable_STATUSGenerator gopter.Gen

// MatchVariable_STATUSGenerator returns a generator of MatchVariable_STATUS instances for property testing.
func MatchVariable_STATUSGenerator() gopter.Gen {
	if matchVariable_STATUSGenerator != nil {
		return matchVariable_STATUSGenerator
	}

	generators := make(map[string]gopter.Gen)
	AddIndependentPropertyGeneratorsForMatchVariable_STATUS(generators)
	matchVariable_STATUSGenerator = gen.Struct(reflect.TypeOf(MatchVariable_STATUS{}), generators)

	return matchVariable_STATUSGenerator
}

// AddIndependentPropertyGeneratorsForMatchVariable_STATUS is a factory method for creating gopter generators
func AddIndependentPropertyGeneratorsForMatchVariable_STATUS(gens map[string]gopter.Gen) {
	gens["Selector"] = gen.PtrOf(gen.AlphaString())
	gens["VariableName"] = gen.PtrOf(gen.OneConstOf(
		MatchVariable_VariableName_STATUS_PostArgs,
		MatchVariable_VariableName_STATUS_QueryString,
		MatchVariable_VariableName_STATUS_RemoteAddr,
		MatchVariable_VariableName_STATUS_RequestBody,
		MatchVariable_VariableName_STATUS_RequestCookies,
		MatchVariable_VariableName_STATUS_RequestHeaders,
		MatchVariable_VariableName_STATUS_RequestMethod,
		MatchVariable_VariableName_STATUS_RequestUri))
}

func Test_OwaspCrsExclusionEntry_STATUS_WhenSerializedToJson_DeserializesAsEqual(t *testing.T) {
	t.Parallel()
	parameters := gopter.DefaultTestParameters()
	parameters.MinSuccessfulTests = 80
	parameters.MaxSize = 3
	properties := gopter.NewProperties(parameters)
	properties.Property(
		"Round trip of OwaspCrsExclusionEntry_STATUS via JSON returns original",
		prop.ForAll(RunJSONSerializationTestForOwaspCrsExclusionEntry_STATUS, OwaspCrsExclusionEntry_STATUSGenerator()))
	properties.TestingRun(t, gopter.NewFormatedReporter(true, 240, os.Stdout))
}

// RunJSONSerializationTestForOwaspCrsExclusionEntry_STATUS runs a test to see if a specific instance of OwaspCrsExclusionEntry_STATUS round trips to JSON and back losslessly
func RunJSONSerializationTestForOwaspCrsExclusionEntry_STATUS(subject OwaspCrsExclusionEntry_STATUS) string {
	// Serialize to JSON
	bin, err := json.Marshal(subject)
	if err != nil {
		return err.Error()
	}

	// Deserialize back into memory
	var actual OwaspCrsExclusionEntry_STATUS
	err = json.Unmarshal(bin, &actual)
	if err != nil {
		return err.Error()
	}

	// Check for outcome
	match := cmp.Equal(subject, actual, cmpopts.EquateEmpty())
	if !match {
		actualFmt := pretty.Sprint(actual)
		subjectFmt := pretty.Sprint(subject)
		result := diff.Diff(subjectFmt, actualFmt)
		return result
	}

	return ""
}

// Generator of OwaspCrsExclusionEntry_STATUS instances for property testing - lazily instantiated by
// OwaspCrsExclusionEntry_STATUSGenerator()
var owaspCrsExclusionEntry_STATUSGenerator gopter.Gen

// OwaspCrsExclusionEntry_STATUSGenerator returns a generator of OwaspCrsExclusionEntry_STATUS instances for property testing.
// We first initialize owaspCrsExclusionEntry_STATUSGenerator with a simplified generator based on the
// fields with primitive types then replacing it with a more complex one that also handles complex fields
// to ensure any cycles in the object graph properly terminate.
func OwaspCrsExclusionEntry_STATUSGenerator() gopter.Gen {
	if owaspCrsExclusionEntry_STATUSGenerator != nil {
		return owaspCrsExclusionEntry_STATUSGenerator
	}

	generators := make(map[string]gopter.Gen)
	AddIndependentPropertyGeneratorsForOwaspCrsExclusionEntry_STATUS(generators)
	owaspCrsExclusionEntry_STATUSGenerator = gen.Struct(reflect.TypeOf(OwaspCrsExclusionEntry_STATUS{}), generators)

	// The above call to gen.Struct() captures the map, so create a new one
	generators = make(map[string]gopter.Gen)
	AddIndependentPropertyGeneratorsForOwaspCrsExclusionEntry_STATUS(generators)
	AddRelatedPropertyGeneratorsForOwaspCrsExclusionEntry_STATUS(generators)
	owaspCrsExclusionEntry_STATUSGenerator = gen.Struct(reflect.TypeOf(OwaspCrsExclusionEntry_STATUS{}), generators)

	return owaspCrsExclusionEntry_STATUSGenerator
}

// AddIndependentPropertyGeneratorsForOwaspCrsExclusionEntry_STATUS is a factory method for creating gopter generators
func AddIndependentPropertyGeneratorsForOwaspCrsExclusionEntry_STATUS(gens map[string]gopter.Gen) {
	gens["MatchVariable"] = gen.PtrOf(gen.OneConstOf(
		OwaspCrsExclusionEntry_MatchVariable_STATUS_RequestArgKeys,
		OwaspCrsExclusionEntry_MatchVariable_STATUS_RequestArgNames,
		OwaspCrsExclusionEntry_MatchVariable_STATUS_RequestArgValues,
		OwaspCrsExclusionEntry_MatchVariable_STATUS_RequestCookieKeys,
		OwaspCrsExclusionEntry_MatchVariable_STATUS_RequestCookieNames,
		OwaspCrsExclusionEntry_MatchVariable_STATUS_RequestCookieValues,
		OwaspCrsExclusionEntry_MatchVariable_STATUS_RequestHeaderKeys,
		OwaspCrsExclusionEntry_MatchVariable_STATUS_RequestHeaderNames,
		OwaspCrsExclusionEntry_MatchVariable_STATUS_RequestHeaderValues))
	gens["Selector"] = gen.PtrOf(gen.AlphaString())
	gens["SelectorMatchOperator"] = gen.PtrOf(gen.OneConstOf(
		OwaspCrsExclusionEntry_SelectorMatchOperator_STATUS_Contains,
		OwaspCrsExclusionEntry_SelectorMatchOperator_STATUS_EndsWith,
		OwaspCrsExclusionEntry_SelectorMatchOperator_STATUS_Equals,
		OwaspCrsExclusionEntry_SelectorMatchOperator_STATUS_EqualsAny,
		OwaspCrsExclusionEntry_SelectorMatchOperator_STATUS_StartsWith))
}

// AddRelatedPropertyGeneratorsForOwaspCrsExclusionEntry_STATUS is a factory method for creating gopter generators
func AddRelatedPropertyGeneratorsForOwaspCrsExclusionEntry_STATUS(gens map[string]gopter.Gen) {
	gens["ExclusionManagedRuleSets"] = gen.SliceOf(ExclusionManagedRuleSet_STATUSGenerator())
}

func Test_PolicySettings_LogScrubbing_STATUS_WhenSerializedToJson_DeserializesAsEqual(t *testing.T) {
	t.Parallel()
	parameters := gopter.DefaultTestParameters()
	parameters.MinSuccessfulTests = 80
	parameters.MaxSize = 3
	properties := gopter.NewProperties(parameters)
	properties.Property(
		"Round trip of PolicySettings_LogScrubbing_STATUS via JSON returns original",
		prop.ForAll(RunJSONSerializationTestForPolicySettings_LogScrubbing_STATUS, PolicySettings_LogScrubbing_STATUSGenerator()))
	properties.TestingRun(t, gopter.NewFormatedReporter(true, 240, os.Stdout))
}

// RunJSONSerializationTestForPolicySettings_LogScrubbing_STATUS runs a test to see if a specific instance of PolicySettings_LogScrubbing_STATUS round trips to JSON and back losslessly
func RunJSONSerializationTestForPolicySettings_LogScrubbing_STATUS(subject PolicySettings_LogScrubbing_STATUS) string {
	// Serialize to JSON
	bin, err := json.Marshal(subject)
	if err != nil {
		return err.Error()
	}

	// Deserialize back into memory
	var actual PolicySettings_LogScrubbing_STATUS
	err = json.Unmarshal(bin, &actual)
	if err != nil {
		return err.Error()
	}

	// Check for outcome
	match := cmp.Equal(subject, actual, cmpopts.EquateEmpty())
	if !match {
		actualFmt := pretty.Sprint(actual)
		subjectFmt := pretty.Sprint(subject)
		result := diff.Diff(subjectFmt, actualFmt)
		return result
	}

	return ""
}

// Generator of PolicySettings_LogScrubbing_STATUS instances for property testing - lazily instantiated by
// PolicySettings_LogScrubbing_STATUSGenerator()
var policySettings_LogScrubbing_STATUSGenerator gopter.Gen

// PolicySettings_LogScrubbing_STATUSGenerator returns a generator of PolicySettings_LogScrubbing_STATUS instances for property testing.
// We first initialize policySettings_LogScrubbing_STATUSGenerator with a simplified generator based on the
// fields with primitive types then replacing it with a more complex one that also handles complex fields
// to ensure any cycles in the object graph properly terminate.
func PolicySettings_LogScrubbing_STATUSGenerator() gopter.Gen {
	if policySettings_LogScrubbing_STATUSGenerator != nil {
		return policySettings_LogScrubbing_STATUSGenerator
	}

	generators := make(map[string]gopter.Gen)
	AddIndependentPropertyGeneratorsForPolicySettings_LogScrubbing_STATUS(generators)
	policySettings_LogScrubbing_STATUSGenerator = gen.Struct(reflect.TypeOf(PolicySettings_LogScrubbing_STATUS{}), generators)

	// The above call to gen.Struct() captures the map, so create a new one
	generators = make(map[string]gopter.Gen)
	AddIndependentPropertyGeneratorsForPolicySettings_LogScrubbing_STATUS(generators)
	AddRelatedPropertyGeneratorsForPolicySettings_LogScrubbing_STATUS(generators)
	policySettings_LogScrubbing_STATUSGenerator = gen.Struct(reflect.TypeOf(PolicySettings_LogScrubbing_STATUS{}), generators)

	return policySettings_LogScrubbing_STATUSGenerator
}

// AddIndependentPropertyGeneratorsForPolicySettings_LogScrubbing_STATUS is a factory method for creating gopter generators
func AddIndependentPropertyGeneratorsForPolicySettings_LogScrubbing_STATUS(gens map[string]gopter.Gen) {
	gens["State"] = gen.PtrOf(gen.OneConstOf(PolicySettings_LogScrubbing_State_STATUS_Disabled, PolicySettings_LogScrubbing_State_STATUS_Enabled))
}

// AddRelatedPropertyGeneratorsForPolicySettings_LogScrubbing_STATUS is a factory method for creating gopter generators
func AddRelatedPropertyGeneratorsForPolicySettings_LogScrubbing_STATUS(gens map[string]gopter.Gen) {
	gens["ScrubbingRules"] = gen.SliceOf(WebApplicationFirewallScrubbingRules_STATUSGenerator())
}

func Test_PolicySettings_STATUS_WhenSerializedToJson_DeserializesAsEqual(t *testing.T) {
	t.Parallel()
	parameters := gopter.DefaultTestParameters()
	parameters.MinSuccessfulTests = 80
	parameters.MaxSize = 3
	properties := gopter.NewProperties(parameters)
	properties.Property(
		"Round trip of PolicySettings_STATUS via JSON returns original",
		prop.ForAll(RunJSONSerializationTestForPolicySettings_STATUS, PolicySettings_STATUSGenerator()))
	properties.TestingRun(t, gopter.NewFormatedReporter(true, 240, os.Stdout))
}

// RunJSONSerializationTestForPolicySettings_STATUS runs a test to see if a specific instance of PolicySettings_STATUS round trips to JSON and back losslessly
func RunJSONSerializationTestForPolicySettings_STATUS(subject PolicySettings_STATUS) string {
	// Serialize to JSON
	bin, err := json.Marshal(subject)
	if err != nil {
		return err.Error()
	}

	// Deserialize back into memory
	var actual PolicySettings_STATUS
	err = json.Unmarshal(bin, &actual)
	if err != nil {
		return err.Error()
	}

	// Check for outcome
	match := cmp.Equal(subject, actual, cmpopts.EquateEmpty())
	if !match {
		actualFmt := pretty.Sprint(actual)
		subjectFmt := pretty.Sprint(subject)
		result := diff.Diff(subjectFmt, actualFmt)
		return result
	}

	return ""
}

// Generator of PolicySettings_STATUS instances for property testing - lazily instantiated by
// PolicySettings_STATUSGenerator()
var policySettings_STATUSGenerator gopter.Gen

// PolicySettings_STATUSGenerator returns a generator of PolicySettings_STATUS instances for property testing.
// We first initialize policySettings_STATUSGenerator with a simplified generator based on the
// fields with primitive types then replacing it with a more complex one that also handles complex fields
// to ensure any cycles in the object graph properly terminate.
func PolicySettings_STATUSGenerator() gopter.Gen {
	if policySettings_STATUSGenerator != nil {
		return policySettings_STATUSGenerator
	}

	generators := make(map[string]gopter.Gen)
	AddIndependentPropertyGeneratorsForPolicySettings_STATUS(generators)
	policySettings_STATUSGenerator = gen.Struct(reflect.TypeOf(PolicySettings_STATUS{}), generators)

	// The above call to gen.Struct() captures the map, so create a new one
	generators = make(map[string]gopter.Gen)
	AddIndependentPropertyGeneratorsForPolicySettings_STATUS(generators)
	AddRelatedPropertyGeneratorsForPolicySettings_STATUS(generators)
	policySettings_STATUSGenerator = gen.Struct(reflect.TypeOf(PolicySettings_STATUS{}), generators)

	return policySettings_STATUSGenerator
}

// AddIndependentPropertyGeneratorsForPolicySettings_STATUS is a factory method for creating gopter generators
func AddIndependentPropertyGeneratorsForPolicySettings_STATUS(gens map[string]gopter.Gen) {
	gens["CustomBlockResponseBody"] = gen.PtrOf(gen.AlphaString())
	gens["CustomBlockResponseStatusCode"] = gen.PtrOf(gen.Int())
	gens["FileUploadEnforcement"] = gen.PtrOf(gen.Bool())
	gens["FileUploadLimitInMb"] = gen.PtrOf(gen.Int())
	gens["JsChallengeCookieExpirationInMins"] = gen.PtrOf(gen.Int())
	gens["MaxRequestBodySizeInKb"] = gen.PtrOf(gen.Int())
	gens["Mode"] = gen.PtrOf(gen.OneConstOf(PolicySettings_Mode_STATUS_Detection, PolicySettings_Mode_STATUS_Prevention))
	gens["RequestBodyCheck"] = gen.PtrOf(gen.Bool())
	gens["RequestBodyEnforcement"] = gen.PtrOf(gen.Bool())
	gens["RequestBodyInspectLimitInKB"] = gen.PtrOf(gen.Int())
	gens["State"] = gen.PtrOf(gen.OneConstOf(PolicySettings_State_STATUS_Disabled, PolicySettings_State_STATUS_Enabled))
}

// AddRelatedPropertyGeneratorsForPolicySettings_STATUS is a factory method for creating gopter generators
func AddRelatedPropertyGeneratorsForPolicySettings_STATUS(gens map[string]gopter.Gen) {
	gens["LogScrubbing"] = gen.PtrOf(PolicySettings_LogScrubbing_STATUSGenerator())
}

func Test_SubResource_STATUS_WhenSerializedToJson_DeserializesAsEqual(t *testing.T) {
	t.Parallel()
	parameters := gopter.DefaultTestParameters()
	parameters.MinSuccessfulTests = 80
	parameters.MaxSize = 3
	properties := gopter.NewProperties(parameters)
	properties.Property(
		"Round trip of SubResource_STATUS via JSON returns original",
		prop.ForAll(RunJSONSerializationTestForSubResource_STATUS, SubResource_STATUSGenerator()))
	properties.TestingRun(t, gopter.NewFormatedReporter(true, 240, os.Stdout))
}

// RunJSONSerializationTestForSubResource_STATUS runs a test to see if a specific instance of SubResource_STATUS round trips to JSON and back losslessly
func RunJSONSerializationTestForSubResource_STATUS(subject SubResource_STATUS) string {
	// Serialize to JSON
	bin, err := json.Marshal(subject)
	if err != nil {
		return err.Error()
	}

	// Deserialize back into memory
	var actual SubResource_STATUS
	err = json.Unmarshal(bin, &actual)
	if err != nil {
		return err.Error()
	}

	// Check for outcome
	match := cmp.Equal(subject, actual, cmpopts.EquateEmpty())
	if !match {
		actualFmt := pretty.Sprint(actual)
		subjectFmt := pretty.Sprint(subject)
		result := diff.Diff(subjectFmt, actualFmt)
		return result
	}

	return ""
}

// Generator of SubResource_STATUS instances for property testing - lazily instantiated by SubResource_STATUSGenerator()
var subResource_STATUSGenerator gopter.Gen

// SubResource_STATUSGenerator returns a generator of SubResource_STATUS instances for property testing.
func SubResource_STATUSGenerator() gopter.Gen {
	if subResource_STATUSGenerator != nil {
		return subResource_STATUSGenerator
	}

	generators := make(map[string]gopter.Gen)
	AddIndependentPropertyGeneratorsForSubResource_STATUS(generators)
	subResource_STATUSGenerator = gen.Struct(reflect.TypeOf(SubResource_STATUS{}), generators)

	return subResource_STATUSGenerator
}

// AddIndependentPropertyGeneratorsForSubResource_STATUS is a factory method for creating gopter generators
func AddIndependentPropertyGeneratorsForSubResource_STATUS(gens map[string]gopter.Gen) {
	gens["Id"] = gen.PtrOf(gen.AlphaString())
}

func Test_WebApplicationFirewallCustomRule_STATUS_WhenSerializedToJson_DeserializesAsEqual(t *testing.T) {
	t.Parallel()
	parameters := gopter.DefaultTestParameters()
	parameters.MinSuccessfulTests = 80
	parameters.MaxSize = 3
	properties := gopter.NewProperties(parameters)
	properties.Property(
		"Round trip of WebApplicationFirewallCustomRule_STATUS via JSON returns original",
		prop.ForAll(RunJSONSerializationTestForWebApplicationFirewallCustomRule_STATUS, WebApplicationFirewallCustomRule_STATUSGenerator()))
	properties.TestingRun(t, gopter.NewFormatedReporter(true, 240, os.Stdout))
}

// RunJSONSerializationTestForWebApplicationFirewallCustomRule_STATUS runs a test to see if a specific instance of WebApplicationFirewallCustomRule_STATUS round trips to JSON and back losslessly
func RunJSONSerializationTestForWebApplicationFirewallCustomRule_STATUS(subject WebApplicationFirewallCustomRule_STATUS) string {
	// Serialize to JSON
	bin, err := json.Marshal(subject)
	if err != nil {
		return err.Error()
	}

	// Deserialize back into memory
	var actual WebApplicationFirewallCustomRule_STATUS
	err = json.Unmarshal(bin, &actual)
	if err != nil {
		return err.Error()
	}

	// Check for outcome
	match := cmp.Equal(subject, actual, cmpopts.EquateEmpty())
	if !match {
		actualFmt := pretty.Sprint(actual)
		subjectFmt := pretty.Sprint(subject)
		result := diff.Diff(subjectFmt, actualFmt)
		return result
	}

	return ""
}

// Generator of WebApplicationFirewallCustomRule_STATUS instances for property testing - lazily instantiated by
// WebApplicationFirewallCustomRule_STATUSGenerator()
var webApplicationFirewallCustomRule_STATUSGenerator gopter.Gen

// WebApplicationFirewallCustomRule_STATUSGenerator returns a generator of WebApplicationFirewallCustomRule_STATUS instances for property testing.
// We first initialize webApplicationFirewallCustomRule_STATUSGenerator with a simplified generator based on the
// fields with primitive types then replacing it with a more complex one that also handles complex fields
// to ensure any cycles in the object graph properly terminate.
func WebApplicationFirewallCustomRule_STATUSGenerator() gopter.Gen {
	if webApplicationFirewallCustomRule_STATUSGenerator != nil {
		return webApplicationFirewallCustomRule_STATUSGenerator
	}

	generators := make(map[string]gopter.Gen)
	AddIndependentPropertyGeneratorsForWebApplicationFirewallCustomRule_STATUS(generators)
	webApplicationFirewallCustomRule_STATUSGenerator = gen.Struct(reflect.TypeOf(WebApplicationFirewallCustomRule_STATUS{}), generators)

	// The above call to gen.Struct() captures the map, so create a new one
	generators = make(map[string]gopter.Gen)
	AddIndependentPropertyGeneratorsForWebApplicationFirewallCustomRule_STATUS(generators)
	AddRelatedPropertyGeneratorsForWebApplicationFirewallCustomRule_STATUS(generators)
	webApplicationFirewallCustomRule_STATUSGenerator = gen.Struct(reflect.TypeOf(WebApplicationFirewallCustomRule_STATUS{}), generators)

	return webApplicationFirewallCustomRule_STATUSGenerator
}

// AddIndependentPropertyGeneratorsForWebApplicationFirewallCustomRule_STATUS is a factory method for creating gopter generators
func AddIndependentPropertyGeneratorsForWebApplicationFirewallCustomRule_STATUS(gens map[string]gopter.Gen) {
	gens["Action"] = gen.PtrOf(gen.OneConstOf(
		WebApplicationFirewallCustomRule_Action_STATUS_Allow,
		WebApplicationFirewallCustomRule_Action_STATUS_Block,
		WebApplicationFirewallCustomRule_Action_STATUS_JSChallenge,
		WebApplicationFirewallCustomRule_Action_STATUS_Log))
	gens["Etag"] = gen.PtrOf(gen.AlphaString())
	gens["Name"] = gen.PtrOf(gen.AlphaString())
	gens["Priority"] = gen.PtrOf(gen.Int())
	gens["RateLimitDuration"] = gen.PtrOf(gen.OneConstOf(WebApplicationFirewallCustomRule_RateLimitDuration_STATUS_FiveMins, WebApplicationFirewallCustomRule_RateLimitDuration_STATUS_OneMin))
	gens["RateLimitThreshold"] = gen.PtrOf(gen.Int())
	gens["RuleType"] = gen.PtrOf(gen.OneConstOf(WebApplicationFirewallCustomRule_RuleType_STATUS_Invalid, WebApplicationFirewallCustomRule_RuleType_STATUS_MatchRule, WebApplicationFirewallCustomRule_RuleType_STATUS_RateLimitRule))
	gens["State"] = gen.PtrOf(gen.OneConstOf(WebApplicationFirewallCustomRule_State_STATUS_Disabled, WebApplicationFirewallCustomRule_State_STATUS_Enabled))
}

// AddRelatedPropertyGeneratorsForWebApplicationFirewallCustomRule_STATUS is a factory method for creating gopter generators
func AddRelatedPropertyGeneratorsForWebApplicationFirewallCustomRule_STATUS(gens map[string]gopter.Gen) {
	gens["GroupByUserSession"] = gen.SliceOf(GroupByUserSession_STATUSGenerator())
	gens["MatchConditions"] = gen.SliceOf(MatchCondition_STATUSGenerator())
}

func Test_WebApplicationFirewallPolicyPropertiesFormat_STATUS_WhenSerializedToJson_DeserializesAsEqual(t *testing.T) {
	t.Parallel()
	parameters := gopter.DefaultTestParameters()
	parameters.MinSuccessfulTests = 80
	parameters.MaxSize = 3
	properties := gopter.NewProperties(parameters)
	properties.Property(
		"Round trip of WebApplicationFirewallPolicyPropertiesFormat_STATUS via JSON returns original",
		prop.ForAll(RunJSONSerializationTestForWebApplicationFirewallPolicyPropertiesFormat_STATUS, WebApplicationFirewallPolicyPropertiesFormat_STATUSGenerator()))
	properties.TestingRun(t, gopter.NewFormatedReporter(true, 240, os.Stdout))
}

// RunJSONSerializationTestForWebApplicationFirewallPolicyPropertiesFormat_STATUS runs a test to see if a specific instance of WebApplicationFirewallPolicyPropertiesFormat_STATUS round trips to JSON and back losslessly
func RunJSONSerializationTestForWebApplicationFirewallPolicyPropertiesFormat_STATUS(subject WebApplicationFirewallPolicyPropertiesFormat_STATUS) string {
	// Serialize to JSON
	bin, err := json.Marshal(subject)
	if err != nil {
		return err.Error()
	}

	// Deserialize back into memory
	var actual WebApplicationFirewallPolicyPropertiesFormat_STATUS
	err = json.Unmarshal(bin, &actual)
	if err != nil {
		return err.Error()
	}

	// Check for outcome
	match := cmp.Equal(subject, actual, cmpopts.EquateEmpty())
	if !match {
		actualFmt := pretty.Sprint(actual)
		subjectFmt := pretty.Sprint(subject)
		result := diff.Diff(subjectFmt, actualFmt)
		return result
	}

	return ""
}

// Generator of WebApplicationFirewallPolicyPropertiesFormat_STATUS instances for property testing - lazily instantiated
// by WebApplicationFirewallPolicyPropertiesFormat_STATUSGenerator()
var webApplicationFirewallPolicyPropertiesFormat_STATUSGenerator gopter.Gen

// WebApplicationFirewallPolicyPropertiesFormat_STATUSGenerator returns a generator of WebApplicationFirewallPolicyPropertiesFormat_STATUS instances for property testing.
// We first initialize webApplicationFirewallPolicyPropertiesFormat_STATUSGenerator with a simplified generator based on the
// fields with primitive types then replacing it with a more complex one that also handles complex fields
// to ensure any cycles in the object graph properly terminate.
func WebApplicationFirewallPolicyPropertiesFormat_STATUSGenerator() gopter.Gen {
	if webApplicationFirewallPolicyPropertiesFormat_STATUSGenerator != nil {
		return webApplicationFirewallPolicyPropertiesFormat_STATUSGenerator
	}

	generators := make(map[string]gopter.Gen)
	AddIndependentPropertyGeneratorsForWebApplicationFirewallPolicyPropertiesFormat_STATUS(generators)
	webApplicationFirewallPolicyPropertiesFormat_STATUSGenerator = gen.Struct(reflect.TypeOf(WebApplicationFirewallPolicyPropertiesFormat_STATUS{}), generators)

	// The above call to gen.Struct() captures the map, so create a new one
	generators = make(map[string]gopter.Gen)
	AddIndependentPropertyGeneratorsForWebApplicationFirewallPolicyPropertiesFormat_STATUS(generators)
	AddRelatedPropertyGeneratorsForWebApplicationFirewallPolicyPropertiesFormat_STATUS(generators)
	webApplicationFirewallPolicyPropertiesFormat_STATUSGenerator = gen.Struct(reflect.TypeOf(WebApplicationFirewallPolicyPropertiesFormat_STATUS{}), generators)

	return webApplicationFirewallPolicyPropertiesFormat_STATUSGenerator
}

// AddIndependentPropertyGeneratorsForWebApplicationFirewallPolicyPropertiesFormat_STATUS is a factory method for creating gopter generators
func AddIndependentPropertyGeneratorsForWebApplicationFirewallPolicyPropertiesFormat_STATUS(gens map[string]gopter.Gen) {
	gens["ProvisioningState"] = gen.PtrOf(gen.OneConstOf(
		ProvisioningState_STATUS_Deleting,
		ProvisioningState_STATUS_Failed,
		ProvisioningState_STATUS_Succeeded,
		ProvisioningState_STATUS_Updating))
	gens["ResourceState"] = gen.PtrOf(gen.OneConstOf(
		WebApplicationFirewallPolicyPropertiesFormat_ResourceState_STATUS_Creating,
		WebApplicationFirewallPolicyPropertiesFormat_ResourceState_STATUS_Deleting,
		WebApplicationFirewallPolicyPropertiesFormat_ResourceState_STATUS_Disabled,
		WebApplicationFirewallPolicyPropertiesFormat_ResourceState_STATUS_Disabling,
		WebApplicationFirewallPolicyPropertiesFormat_ResourceState_STATUS_Enabled,
		WebApplicationFirewallPolicyPropertiesFormat_ResourceState_STATUS_Enabling))
}

// AddRelatedPropertyGeneratorsForWebApplicationFirewallPolicyPropertiesFormat_STATUS is a factory method for creating gopter generators
func AddRelatedPropertyGeneratorsForWebApplicationFirewallPolicyPropertiesFormat_STATUS(gens map[string]gopter.Gen) {
	gens["ApplicationGateways"] = gen.SliceOf(ApplicationGateway_STATUS_ApplicationGatewayWebApplicationFirewallPolicy_SubResourceEmbeddedGenerator())
	gens["CustomRules"] = gen.SliceOf(WebApplicationFirewallCustomRule_STATUSGenerator())
	gens["HttpListeners"] = gen.SliceOf(SubResource_STATUSGenerator())
	gens["ManagedRules"] = gen.PtrOf(ManagedRulesDefinition_STATUSGenerator())
	gens["PathBasedRules"] = gen.SliceOf(SubResource_STATUSGenerator())
	gens["PolicySettings"] = gen.PtrOf(PolicySettings_STATUSGenerator())
}

func Test_WebApplicationFirewallPolicy_STATUS_WhenSerializedToJson_DeserializesAsEqual(t *testing.T) {
	t.Parallel()
	parameters := gopter.DefaultTestParameters()
	parameters.MinSuccessfulTests = 80
	parameters.MaxSize = 3
	properties := gopter.NewProperties(parameters)
	properties.Property(
		"Round trip of WebApplicationFirewallPolicy_STATUS via JSON returns original",
		prop.ForAll(RunJSONSerializationTestForWebApplicationFirewallPolicy_STATUS, WebApplicationFirewallPolicy_STATUSGenerator()))
	properties.TestingRun(t, gopter.NewFormatedReporter(true, 240, os.Stdout))
}

// RunJSONSerializationTestForWebApplicationFirewallPolicy_STATUS runs a test to see if a specific instance of WebApplicationFirewallPolicy_STATUS round trips to JSON and back losslessly
func RunJSONSerializationTestForWebApplicationFirewallPolicy_STATUS(subject WebApplicationFirewallPolicy_STATUS) string {
	// Serialize to JSON
	bin, err := json.Marshal(subject)
	if err != nil {
		return err.Error()
	}

	// Deserialize back into memory
	var actual WebApplicationFirewallPolicy_STATUS
	err = json.Unmarshal(bin, &actual)
	if err != nil {
		return err.Error()
	}

	// Check for outcome
	match := cmp.Equal(subject, actual, cmpopts.EquateEmpty())
	if !match {
		actualFmt := pretty.Sprint(actual)
		subjectFmt := pretty.Sprint(subject)
		result := diff.Diff(subjectFmt, actualFmt)
		return result
	}

	return ""
}

// Generator of WebApplicationFirewallPolicy_STATUS instances for property testing - lazily instantiated by
// WebApplicationFirewallPolicy_STATUSGenerator()
var webApplicationFirewallPolicy_STATUSGenerator gopter.Gen

// WebApplicationFirewallPolicy_STATUSGenerator returns a generator of WebApplicationFirewallPolicy_STATUS instances for property testing.
// We first initialize webApplicationFirewallPolicy_STATUSGenerator with a simplified generator based on the
// fields with primitive types then replacing it with a more complex one that also handles complex fields
// to ensure any cycles in the object graph properly terminate.
func WebApplicationFirewallPolicy_STATUSGenerator() gopter.Gen {
	if webApplicationFirewallPolicy_STATUSGenerator != nil {
		return webApplicationFirewallPolicy_STATUSGenerator
	}

	generators := make(map[string]gopter.Gen)
	AddIndependentPropertyGeneratorsForWebApplicationFirewallPolicy_STATUS(generators)
	webApplicationFirewallPolicy_STATUSGenerator = gen.Struct(reflect.TypeOf(WebApplicationFirewallPolicy_STATUS{}), generators)

	// The above call to gen.Struct() captures the map, so create a new one
	generators = make(map[string]gopter.Gen)
	AddIndependentPropertyGeneratorsForWebApplicationFirewallPolicy_STATUS(generators)
	AddRelatedPropertyGeneratorsForWebApplicationFirewallPolicy_STATUS(generators)
	webApplicationFirewallPolicy_STATUSGenerator = gen.Struct(reflect.TypeOf(WebApplicationFirewallPolicy_STATUS{}), generators)

	return webApplicationFirewallPolicy_STATUSGenerator
}

// AddIndependentPropertyGeneratorsForWebApplicationFirewallPolicy_STATUS is a factory method for creating gopter generators
func AddIndependentPropertyGeneratorsForWebApplicationFirewallPolicy_STATUS(gens map[string]gopter.Gen) {
	gens["Etag"] = gen.PtrOf(gen.AlphaString())
	gens["Id"] = gen.PtrOf(gen.AlphaString())
	gens["Location"] = gen.PtrOf(gen.AlphaString())
	gens["Name"] = gen.PtrOf(gen.AlphaString())
	gens["Tags"] = gen.MapOf(
		gen.AlphaString(),
		gen.AlphaString())
	gens["Type"] = gen.PtrOf(gen.AlphaString())
}

// AddRelatedPropertyGeneratorsForWebApplicationFirewallPolicy_STATUS is a factory method for creating gopter generators
func AddRelatedPropertyGeneratorsForWebApplicationFirewallPolicy_STATUS(gens map[string]gopter.Gen) {
	gens["Properties"] = gen.PtrOf(WebApplicationFirewallPolicyPropertiesFormat_STATUSGenerator())
}

func Test_WebApplicationFirewallScrubbingRules_STATUS_WhenSerializedToJson_DeserializesAsEqual(t *testing.T) {
	t.Parallel()
	parameters := gopter.DefaultTestParameters()
	parameters.MinSuccessfulTests = 80
	parameters.MaxSize = 3
	properties := gopter.NewProperties(parameters)
	properties.Property(
		"Round trip of WebApplicationFirewallScrubbingRules_STATUS via JSON returns original",
		prop.ForAll(RunJSONSerializationTestForWebApplicationFirewallScrubbingRules_STATUS, WebApplicationFirewallScrubbingRules_STATUSGenerator()))
	properties.TestingRun(t, gopter.NewFormatedReporter(true, 240, os.Stdout))
}

// RunJSONSerializationTestForWebApplicationFirewallScrubbingRules_STATUS runs a test to see if a specific instance of WebApplicationFirewallScrubbingRules_STATUS round trips to JSON and back losslessly
func RunJSONSerializationTestForWebApplicationFirewallScrubbingRules_STATUS(subject WebApplicationFirewallScrubbingRules_STATUS) string {
	// Serialize to JSON
	bin, err := json.Marshal(subject)
	if err != nil {
		return err.Error()
	}

	// Deserialize back into memory
	var actual WebApplicationFirewallScrubbingRules_STATUS
	err = json.Unmarshal(bin, &actual)
	if err != nil {
		return err.Error()
	}

	// Check for outcome
	match := cmp.Equal(subject, actual, cmpopts.EquateEmpty())
	if !match {
		actualFmt := pretty.Sprint(actual)
		subjectFmt := pretty.Sprint(subject)
		result := diff.Diff(subjectFmt, actualFmt)
		return result
	}

	return ""
}

// Generator of WebApplicationFirewallScrubbingRules_STATUS instances for property testing - lazily instantiated by
// WebApplicationFirewallScrubbingRules_STATUSGenerator()
var webApplicationFirewallScrubbingRules_STATUSGenerator gopter.Gen

// WebApplicationFirewallScrubbingRules_STATUSGenerator returns a generator of WebApplicationFirewallScrubbingRules_STATUS instances for property testing.
func WebApplicationFirewallScrubbingRules_STATUSGenerator() gopter.Gen {
	if webApplicationFirewallScrubbingRules_STATUSGenerator != nil {
		return webApplicationFirewallScrubbingRules_STATUSGenerator
	}

	generators := make(map[string]gopter.Gen)
	AddIndependentPropertyGeneratorsForWebApplicationFirewallScrubbingRules_STATUS(generators)
	webApplicationFirewallScrubbingRules_STATUSGenerator = gen.Struct(reflect.TypeOf(WebApplicationFirewallScrubbingRules_STATUS{}), generators)

	return webApplicationFirewallScrubbingRules_STATUSGenerator
}

// AddIndependentPropertyGeneratorsForWebApplicationFirewallScrubbingRules_STATUS is a factory method for creating gopter generators
func AddIndependentPropertyGeneratorsForWebApplicationFirewallScrubbingRules_STATUS(gens map[string]gopter.Gen) {
	gens["MatchVariable"] = gen.PtrOf(gen.OneConstOf(
		WebApplicationFirewallScrubbingRules_MatchVariable_STATUS_RequestArgNames,
		WebApplicationFirewallScrubbingRules_MatchVariable_STATUS_RequestCookieNames,
		WebApplicationFirewallScrubbingRules_MatchVariable_STATUS_RequestHeaderNames,
		WebApplicationFirewallScrubbingRules_MatchVariable_STATUS_RequestIPAddress,
		WebApplicationFirewallScrubbingRules_MatchVariable_STATUS_RequestJSONArgNames,
		WebApplicationFirewallScrubbingRules_MatchVariable_STATUS_RequestPostArgNames))
	gens["Selector"] = gen.PtrOf(gen.AlphaString())
	gens["SelectorMatchOperator"] = gen.PtrOf(gen.OneConstOf(WebApplicationFirewallScrubbingRules_SelectorMatchOperator_STATUS_Equals, WebApplicationFirewallScrubbingRules_SelectorMatchOperator_STATUS_EqualsAny))
	gens["State"] = gen.PtrOf(gen.OneConstOf(WebApplicationFirewallScrubbingRules_State_STATUS_Disabled, WebApplicationFirewallScrubbingRules_State_STATUS_Enabled))
}
