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

import (
	"encoding/json"
	storage "github.com/Azure/azure-service-operator/v2/api/synapse/v1api20210601/storage"
	"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_AutoPauseProperties_WhenPropertiesConverted_RoundTripsWithoutLoss(t *testing.T) {
	t.Parallel()
	parameters := gopter.DefaultTestParameters()
	parameters.MaxSize = 10
	properties := gopter.NewProperties(parameters)
	properties.Property(
		"Round trip from AutoPauseProperties to AutoPauseProperties via AssignProperties_To_AutoPauseProperties & AssignProperties_From_AutoPauseProperties returns original",
		prop.ForAll(RunPropertyAssignmentTestForAutoPauseProperties, AutoPausePropertiesGenerator()))
	properties.TestingRun(t, gopter.NewFormatedReporter(false, 240, os.Stdout))
}

// RunPropertyAssignmentTestForAutoPauseProperties tests if a specific instance of AutoPauseProperties can be assigned to storage and back losslessly
func RunPropertyAssignmentTestForAutoPauseProperties(subject AutoPauseProperties) string {
	// Copy subject to make sure assignment doesn't modify it
	copied := subject.DeepCopy()

	// Use AssignPropertiesTo() for the first stage of conversion
	var other storage.AutoPauseProperties
	err := copied.AssignProperties_To_AutoPauseProperties(&other)
	if err != nil {
		return err.Error()
	}

	// Use AssignPropertiesFrom() to convert back to our original type
	var actual AutoPauseProperties
	err = actual.AssignProperties_From_AutoPauseProperties(&other)
	if err != nil {
		return err.Error()
	}

	// Check for a match
	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 ""
}

func Test_AutoPauseProperties_WhenSerializedToJson_DeserializesAsEqual(t *testing.T) {
	t.Parallel()
	parameters := gopter.DefaultTestParameters()
	parameters.MinSuccessfulTests = 100
	parameters.MaxSize = 3
	properties := gopter.NewProperties(parameters)
	properties.Property(
		"Round trip of AutoPauseProperties via JSON returns original",
		prop.ForAll(RunJSONSerializationTestForAutoPauseProperties, AutoPausePropertiesGenerator()))
	properties.TestingRun(t, gopter.NewFormatedReporter(true, 240, os.Stdout))
}

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

	// Deserialize back into memory
	var actual AutoPauseProperties
	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 AutoPauseProperties instances for property testing - lazily instantiated by
// AutoPausePropertiesGenerator()
var autoPausePropertiesGenerator gopter.Gen

// AutoPausePropertiesGenerator returns a generator of AutoPauseProperties instances for property testing.
func AutoPausePropertiesGenerator() gopter.Gen {
	if autoPausePropertiesGenerator != nil {
		return autoPausePropertiesGenerator
	}

	generators := make(map[string]gopter.Gen)
	AddIndependentPropertyGeneratorsForAutoPauseProperties(generators)
	autoPausePropertiesGenerator = gen.Struct(reflect.TypeOf(AutoPauseProperties{}), generators)

	return autoPausePropertiesGenerator
}

// AddIndependentPropertyGeneratorsForAutoPauseProperties is a factory method for creating gopter generators
func AddIndependentPropertyGeneratorsForAutoPauseProperties(gens map[string]gopter.Gen) {
	gens["DelayInMinutes"] = gen.PtrOf(gen.Int())
	gens["Enabled"] = gen.PtrOf(gen.Bool())
}

func Test_AutoPauseProperties_STATUS_WhenPropertiesConverted_RoundTripsWithoutLoss(t *testing.T) {
	t.Parallel()
	parameters := gopter.DefaultTestParameters()
	parameters.MaxSize = 10
	properties := gopter.NewProperties(parameters)
	properties.Property(
		"Round trip from AutoPauseProperties_STATUS to AutoPauseProperties_STATUS via AssignProperties_To_AutoPauseProperties_STATUS & AssignProperties_From_AutoPauseProperties_STATUS returns original",
		prop.ForAll(RunPropertyAssignmentTestForAutoPauseProperties_STATUS, AutoPauseProperties_STATUSGenerator()))
	properties.TestingRun(t, gopter.NewFormatedReporter(false, 240, os.Stdout))
}

// RunPropertyAssignmentTestForAutoPauseProperties_STATUS tests if a specific instance of AutoPauseProperties_STATUS can be assigned to storage and back losslessly
func RunPropertyAssignmentTestForAutoPauseProperties_STATUS(subject AutoPauseProperties_STATUS) string {
	// Copy subject to make sure assignment doesn't modify it
	copied := subject.DeepCopy()

	// Use AssignPropertiesTo() for the first stage of conversion
	var other storage.AutoPauseProperties_STATUS
	err := copied.AssignProperties_To_AutoPauseProperties_STATUS(&other)
	if err != nil {
		return err.Error()
	}

	// Use AssignPropertiesFrom() to convert back to our original type
	var actual AutoPauseProperties_STATUS
	err = actual.AssignProperties_From_AutoPauseProperties_STATUS(&other)
	if err != nil {
		return err.Error()
	}

	// Check for a match
	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 ""
}

func Test_AutoPauseProperties_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 AutoPauseProperties_STATUS via JSON returns original",
		prop.ForAll(RunJSONSerializationTestForAutoPauseProperties_STATUS, AutoPauseProperties_STATUSGenerator()))
	properties.TestingRun(t, gopter.NewFormatedReporter(true, 240, os.Stdout))
}

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

	// Deserialize back into memory
	var actual AutoPauseProperties_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 AutoPauseProperties_STATUS instances for property testing - lazily instantiated by
// AutoPauseProperties_STATUSGenerator()
var autoPauseProperties_STATUSGenerator gopter.Gen

// AutoPauseProperties_STATUSGenerator returns a generator of AutoPauseProperties_STATUS instances for property testing.
func AutoPauseProperties_STATUSGenerator() gopter.Gen {
	if autoPauseProperties_STATUSGenerator != nil {
		return autoPauseProperties_STATUSGenerator
	}

	generators := make(map[string]gopter.Gen)
	AddIndependentPropertyGeneratorsForAutoPauseProperties_STATUS(generators)
	autoPauseProperties_STATUSGenerator = gen.Struct(reflect.TypeOf(AutoPauseProperties_STATUS{}), generators)

	return autoPauseProperties_STATUSGenerator
}

// AddIndependentPropertyGeneratorsForAutoPauseProperties_STATUS is a factory method for creating gopter generators
func AddIndependentPropertyGeneratorsForAutoPauseProperties_STATUS(gens map[string]gopter.Gen) {
	gens["DelayInMinutes"] = gen.PtrOf(gen.Int())
	gens["Enabled"] = gen.PtrOf(gen.Bool())
}

func Test_AutoScaleProperties_WhenPropertiesConverted_RoundTripsWithoutLoss(t *testing.T) {
	t.Parallel()
	parameters := gopter.DefaultTestParameters()
	parameters.MaxSize = 10
	properties := gopter.NewProperties(parameters)
	properties.Property(
		"Round trip from AutoScaleProperties to AutoScaleProperties via AssignProperties_To_AutoScaleProperties & AssignProperties_From_AutoScaleProperties returns original",
		prop.ForAll(RunPropertyAssignmentTestForAutoScaleProperties, AutoScalePropertiesGenerator()))
	properties.TestingRun(t, gopter.NewFormatedReporter(false, 240, os.Stdout))
}

// RunPropertyAssignmentTestForAutoScaleProperties tests if a specific instance of AutoScaleProperties can be assigned to storage and back losslessly
func RunPropertyAssignmentTestForAutoScaleProperties(subject AutoScaleProperties) string {
	// Copy subject to make sure assignment doesn't modify it
	copied := subject.DeepCopy()

	// Use AssignPropertiesTo() for the first stage of conversion
	var other storage.AutoScaleProperties
	err := copied.AssignProperties_To_AutoScaleProperties(&other)
	if err != nil {
		return err.Error()
	}

	// Use AssignPropertiesFrom() to convert back to our original type
	var actual AutoScaleProperties
	err = actual.AssignProperties_From_AutoScaleProperties(&other)
	if err != nil {
		return err.Error()
	}

	// Check for a match
	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 ""
}

func Test_AutoScaleProperties_WhenSerializedToJson_DeserializesAsEqual(t *testing.T) {
	t.Parallel()
	parameters := gopter.DefaultTestParameters()
	parameters.MinSuccessfulTests = 100
	parameters.MaxSize = 3
	properties := gopter.NewProperties(parameters)
	properties.Property(
		"Round trip of AutoScaleProperties via JSON returns original",
		prop.ForAll(RunJSONSerializationTestForAutoScaleProperties, AutoScalePropertiesGenerator()))
	properties.TestingRun(t, gopter.NewFormatedReporter(true, 240, os.Stdout))
}

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

	// Deserialize back into memory
	var actual AutoScaleProperties
	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 AutoScaleProperties instances for property testing - lazily instantiated by
// AutoScalePropertiesGenerator()
var autoScalePropertiesGenerator gopter.Gen

// AutoScalePropertiesGenerator returns a generator of AutoScaleProperties instances for property testing.
func AutoScalePropertiesGenerator() gopter.Gen {
	if autoScalePropertiesGenerator != nil {
		return autoScalePropertiesGenerator
	}

	generators := make(map[string]gopter.Gen)
	AddIndependentPropertyGeneratorsForAutoScaleProperties(generators)
	autoScalePropertiesGenerator = gen.Struct(reflect.TypeOf(AutoScaleProperties{}), generators)

	return autoScalePropertiesGenerator
}

// AddIndependentPropertyGeneratorsForAutoScaleProperties is a factory method for creating gopter generators
func AddIndependentPropertyGeneratorsForAutoScaleProperties(gens map[string]gopter.Gen) {
	gens["Enabled"] = gen.PtrOf(gen.Bool())
	gens["MaxNodeCount"] = gen.PtrOf(gen.Int())
	gens["MinNodeCount"] = gen.PtrOf(gen.Int())
}

func Test_AutoScaleProperties_STATUS_WhenPropertiesConverted_RoundTripsWithoutLoss(t *testing.T) {
	t.Parallel()
	parameters := gopter.DefaultTestParameters()
	parameters.MaxSize = 10
	properties := gopter.NewProperties(parameters)
	properties.Property(
		"Round trip from AutoScaleProperties_STATUS to AutoScaleProperties_STATUS via AssignProperties_To_AutoScaleProperties_STATUS & AssignProperties_From_AutoScaleProperties_STATUS returns original",
		prop.ForAll(RunPropertyAssignmentTestForAutoScaleProperties_STATUS, AutoScaleProperties_STATUSGenerator()))
	properties.TestingRun(t, gopter.NewFormatedReporter(false, 240, os.Stdout))
}

// RunPropertyAssignmentTestForAutoScaleProperties_STATUS tests if a specific instance of AutoScaleProperties_STATUS can be assigned to storage and back losslessly
func RunPropertyAssignmentTestForAutoScaleProperties_STATUS(subject AutoScaleProperties_STATUS) string {
	// Copy subject to make sure assignment doesn't modify it
	copied := subject.DeepCopy()

	// Use AssignPropertiesTo() for the first stage of conversion
	var other storage.AutoScaleProperties_STATUS
	err := copied.AssignProperties_To_AutoScaleProperties_STATUS(&other)
	if err != nil {
		return err.Error()
	}

	// Use AssignPropertiesFrom() to convert back to our original type
	var actual AutoScaleProperties_STATUS
	err = actual.AssignProperties_From_AutoScaleProperties_STATUS(&other)
	if err != nil {
		return err.Error()
	}

	// Check for a match
	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 ""
}

func Test_AutoScaleProperties_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 AutoScaleProperties_STATUS via JSON returns original",
		prop.ForAll(RunJSONSerializationTestForAutoScaleProperties_STATUS, AutoScaleProperties_STATUSGenerator()))
	properties.TestingRun(t, gopter.NewFormatedReporter(true, 240, os.Stdout))
}

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

	// Deserialize back into memory
	var actual AutoScaleProperties_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 AutoScaleProperties_STATUS instances for property testing - lazily instantiated by
// AutoScaleProperties_STATUSGenerator()
var autoScaleProperties_STATUSGenerator gopter.Gen

// AutoScaleProperties_STATUSGenerator returns a generator of AutoScaleProperties_STATUS instances for property testing.
func AutoScaleProperties_STATUSGenerator() gopter.Gen {
	if autoScaleProperties_STATUSGenerator != nil {
		return autoScaleProperties_STATUSGenerator
	}

	generators := make(map[string]gopter.Gen)
	AddIndependentPropertyGeneratorsForAutoScaleProperties_STATUS(generators)
	autoScaleProperties_STATUSGenerator = gen.Struct(reflect.TypeOf(AutoScaleProperties_STATUS{}), generators)

	return autoScaleProperties_STATUSGenerator
}

// AddIndependentPropertyGeneratorsForAutoScaleProperties_STATUS is a factory method for creating gopter generators
func AddIndependentPropertyGeneratorsForAutoScaleProperties_STATUS(gens map[string]gopter.Gen) {
	gens["Enabled"] = gen.PtrOf(gen.Bool())
	gens["MaxNodeCount"] = gen.PtrOf(gen.Int())
	gens["MinNodeCount"] = gen.PtrOf(gen.Int())
}

func Test_DynamicExecutorAllocation_WhenPropertiesConverted_RoundTripsWithoutLoss(t *testing.T) {
	t.Parallel()
	parameters := gopter.DefaultTestParameters()
	parameters.MaxSize = 10
	properties := gopter.NewProperties(parameters)
	properties.Property(
		"Round trip from DynamicExecutorAllocation to DynamicExecutorAllocation via AssignProperties_To_DynamicExecutorAllocation & AssignProperties_From_DynamicExecutorAllocation returns original",
		prop.ForAll(RunPropertyAssignmentTestForDynamicExecutorAllocation, DynamicExecutorAllocationGenerator()))
	properties.TestingRun(t, gopter.NewFormatedReporter(false, 240, os.Stdout))
}

// RunPropertyAssignmentTestForDynamicExecutorAllocation tests if a specific instance of DynamicExecutorAllocation can be assigned to storage and back losslessly
func RunPropertyAssignmentTestForDynamicExecutorAllocation(subject DynamicExecutorAllocation) string {
	// Copy subject to make sure assignment doesn't modify it
	copied := subject.DeepCopy()

	// Use AssignPropertiesTo() for the first stage of conversion
	var other storage.DynamicExecutorAllocation
	err := copied.AssignProperties_To_DynamicExecutorAllocation(&other)
	if err != nil {
		return err.Error()
	}

	// Use AssignPropertiesFrom() to convert back to our original type
	var actual DynamicExecutorAllocation
	err = actual.AssignProperties_From_DynamicExecutorAllocation(&other)
	if err != nil {
		return err.Error()
	}

	// Check for a match
	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 ""
}

func Test_DynamicExecutorAllocation_WhenSerializedToJson_DeserializesAsEqual(t *testing.T) {
	t.Parallel()
	parameters := gopter.DefaultTestParameters()
	parameters.MinSuccessfulTests = 100
	parameters.MaxSize = 3
	properties := gopter.NewProperties(parameters)
	properties.Property(
		"Round trip of DynamicExecutorAllocation via JSON returns original",
		prop.ForAll(RunJSONSerializationTestForDynamicExecutorAllocation, DynamicExecutorAllocationGenerator()))
	properties.TestingRun(t, gopter.NewFormatedReporter(true, 240, os.Stdout))
}

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

	// Deserialize back into memory
	var actual DynamicExecutorAllocation
	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 DynamicExecutorAllocation instances for property testing - lazily instantiated by
// DynamicExecutorAllocationGenerator()
var dynamicExecutorAllocationGenerator gopter.Gen

// DynamicExecutorAllocationGenerator returns a generator of DynamicExecutorAllocation instances for property testing.
func DynamicExecutorAllocationGenerator() gopter.Gen {
	if dynamicExecutorAllocationGenerator != nil {
		return dynamicExecutorAllocationGenerator
	}

	generators := make(map[string]gopter.Gen)
	AddIndependentPropertyGeneratorsForDynamicExecutorAllocation(generators)
	dynamicExecutorAllocationGenerator = gen.Struct(reflect.TypeOf(DynamicExecutorAllocation{}), generators)

	return dynamicExecutorAllocationGenerator
}

// AddIndependentPropertyGeneratorsForDynamicExecutorAllocation is a factory method for creating gopter generators
func AddIndependentPropertyGeneratorsForDynamicExecutorAllocation(gens map[string]gopter.Gen) {
	gens["Enabled"] = gen.PtrOf(gen.Bool())
	gens["MaxExecutors"] = gen.PtrOf(gen.Int())
	gens["MinExecutors"] = gen.PtrOf(gen.Int())
}

func Test_DynamicExecutorAllocation_STATUS_WhenPropertiesConverted_RoundTripsWithoutLoss(t *testing.T) {
	t.Parallel()
	parameters := gopter.DefaultTestParameters()
	parameters.MaxSize = 10
	properties := gopter.NewProperties(parameters)
	properties.Property(
		"Round trip from DynamicExecutorAllocation_STATUS to DynamicExecutorAllocation_STATUS via AssignProperties_To_DynamicExecutorAllocation_STATUS & AssignProperties_From_DynamicExecutorAllocation_STATUS returns original",
		prop.ForAll(RunPropertyAssignmentTestForDynamicExecutorAllocation_STATUS, DynamicExecutorAllocation_STATUSGenerator()))
	properties.TestingRun(t, gopter.NewFormatedReporter(false, 240, os.Stdout))
}

// RunPropertyAssignmentTestForDynamicExecutorAllocation_STATUS tests if a specific instance of DynamicExecutorAllocation_STATUS can be assigned to storage and back losslessly
func RunPropertyAssignmentTestForDynamicExecutorAllocation_STATUS(subject DynamicExecutorAllocation_STATUS) string {
	// Copy subject to make sure assignment doesn't modify it
	copied := subject.DeepCopy()

	// Use AssignPropertiesTo() for the first stage of conversion
	var other storage.DynamicExecutorAllocation_STATUS
	err := copied.AssignProperties_To_DynamicExecutorAllocation_STATUS(&other)
	if err != nil {
		return err.Error()
	}

	// Use AssignPropertiesFrom() to convert back to our original type
	var actual DynamicExecutorAllocation_STATUS
	err = actual.AssignProperties_From_DynamicExecutorAllocation_STATUS(&other)
	if err != nil {
		return err.Error()
	}

	// Check for a match
	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 ""
}

func Test_DynamicExecutorAllocation_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 DynamicExecutorAllocation_STATUS via JSON returns original",
		prop.ForAll(RunJSONSerializationTestForDynamicExecutorAllocation_STATUS, DynamicExecutorAllocation_STATUSGenerator()))
	properties.TestingRun(t, gopter.NewFormatedReporter(true, 240, os.Stdout))
}

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

	// Deserialize back into memory
	var actual DynamicExecutorAllocation_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 DynamicExecutorAllocation_STATUS instances for property testing - lazily instantiated by
// DynamicExecutorAllocation_STATUSGenerator()
var dynamicExecutorAllocation_STATUSGenerator gopter.Gen

// DynamicExecutorAllocation_STATUSGenerator returns a generator of DynamicExecutorAllocation_STATUS instances for property testing.
func DynamicExecutorAllocation_STATUSGenerator() gopter.Gen {
	if dynamicExecutorAllocation_STATUSGenerator != nil {
		return dynamicExecutorAllocation_STATUSGenerator
	}

	generators := make(map[string]gopter.Gen)
	AddIndependentPropertyGeneratorsForDynamicExecutorAllocation_STATUS(generators)
	dynamicExecutorAllocation_STATUSGenerator = gen.Struct(reflect.TypeOf(DynamicExecutorAllocation_STATUS{}), generators)

	return dynamicExecutorAllocation_STATUSGenerator
}

// AddIndependentPropertyGeneratorsForDynamicExecutorAllocation_STATUS is a factory method for creating gopter generators
func AddIndependentPropertyGeneratorsForDynamicExecutorAllocation_STATUS(gens map[string]gopter.Gen) {
	gens["Enabled"] = gen.PtrOf(gen.Bool())
	gens["MaxExecutors"] = gen.PtrOf(gen.Int())
	gens["MinExecutors"] = gen.PtrOf(gen.Int())
}

func Test_LibraryInfo_WhenPropertiesConverted_RoundTripsWithoutLoss(t *testing.T) {
	t.Parallel()
	parameters := gopter.DefaultTestParameters()
	parameters.MaxSize = 10
	properties := gopter.NewProperties(parameters)
	properties.Property(
		"Round trip from LibraryInfo to LibraryInfo via AssignProperties_To_LibraryInfo & AssignProperties_From_LibraryInfo returns original",
		prop.ForAll(RunPropertyAssignmentTestForLibraryInfo, LibraryInfoGenerator()))
	properties.TestingRun(t, gopter.NewFormatedReporter(false, 240, os.Stdout))
}

// RunPropertyAssignmentTestForLibraryInfo tests if a specific instance of LibraryInfo can be assigned to storage and back losslessly
func RunPropertyAssignmentTestForLibraryInfo(subject LibraryInfo) string {
	// Copy subject to make sure assignment doesn't modify it
	copied := subject.DeepCopy()

	// Use AssignPropertiesTo() for the first stage of conversion
	var other storage.LibraryInfo
	err := copied.AssignProperties_To_LibraryInfo(&other)
	if err != nil {
		return err.Error()
	}

	// Use AssignPropertiesFrom() to convert back to our original type
	var actual LibraryInfo
	err = actual.AssignProperties_From_LibraryInfo(&other)
	if err != nil {
		return err.Error()
	}

	// Check for a match
	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 ""
}

func Test_LibraryInfo_WhenSerializedToJson_DeserializesAsEqual(t *testing.T) {
	t.Parallel()
	parameters := gopter.DefaultTestParameters()
	parameters.MinSuccessfulTests = 100
	parameters.MaxSize = 3
	properties := gopter.NewProperties(parameters)
	properties.Property(
		"Round trip of LibraryInfo via JSON returns original",
		prop.ForAll(RunJSONSerializationTestForLibraryInfo, LibraryInfoGenerator()))
	properties.TestingRun(t, gopter.NewFormatedReporter(true, 240, os.Stdout))
}

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

	// Deserialize back into memory
	var actual LibraryInfo
	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 LibraryInfo instances for property testing - lazily instantiated by LibraryInfoGenerator()
var libraryInfoGenerator gopter.Gen

// LibraryInfoGenerator returns a generator of LibraryInfo instances for property testing.
func LibraryInfoGenerator() gopter.Gen {
	if libraryInfoGenerator != nil {
		return libraryInfoGenerator
	}

	generators := make(map[string]gopter.Gen)
	AddIndependentPropertyGeneratorsForLibraryInfo(generators)
	libraryInfoGenerator = gen.Struct(reflect.TypeOf(LibraryInfo{}), generators)

	return libraryInfoGenerator
}

// AddIndependentPropertyGeneratorsForLibraryInfo is a factory method for creating gopter generators
func AddIndependentPropertyGeneratorsForLibraryInfo(gens map[string]gopter.Gen) {
	gens["ContainerName"] = gen.PtrOf(gen.AlphaString())
	gens["Name"] = gen.PtrOf(gen.AlphaString())
	gens["Path"] = gen.PtrOf(gen.AlphaString())
	gens["Type"] = gen.PtrOf(gen.AlphaString())
}

func Test_LibraryInfo_STATUS_WhenPropertiesConverted_RoundTripsWithoutLoss(t *testing.T) {
	t.Parallel()
	parameters := gopter.DefaultTestParameters()
	parameters.MaxSize = 10
	properties := gopter.NewProperties(parameters)
	properties.Property(
		"Round trip from LibraryInfo_STATUS to LibraryInfo_STATUS via AssignProperties_To_LibraryInfo_STATUS & AssignProperties_From_LibraryInfo_STATUS returns original",
		prop.ForAll(RunPropertyAssignmentTestForLibraryInfo_STATUS, LibraryInfo_STATUSGenerator()))
	properties.TestingRun(t, gopter.NewFormatedReporter(false, 240, os.Stdout))
}

// RunPropertyAssignmentTestForLibraryInfo_STATUS tests if a specific instance of LibraryInfo_STATUS can be assigned to storage and back losslessly
func RunPropertyAssignmentTestForLibraryInfo_STATUS(subject LibraryInfo_STATUS) string {
	// Copy subject to make sure assignment doesn't modify it
	copied := subject.DeepCopy()

	// Use AssignPropertiesTo() for the first stage of conversion
	var other storage.LibraryInfo_STATUS
	err := copied.AssignProperties_To_LibraryInfo_STATUS(&other)
	if err != nil {
		return err.Error()
	}

	// Use AssignPropertiesFrom() to convert back to our original type
	var actual LibraryInfo_STATUS
	err = actual.AssignProperties_From_LibraryInfo_STATUS(&other)
	if err != nil {
		return err.Error()
	}

	// Check for a match
	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 ""
}

func Test_LibraryInfo_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 LibraryInfo_STATUS via JSON returns original",
		prop.ForAll(RunJSONSerializationTestForLibraryInfo_STATUS, LibraryInfo_STATUSGenerator()))
	properties.TestingRun(t, gopter.NewFormatedReporter(true, 240, os.Stdout))
}

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

	// Deserialize back into memory
	var actual LibraryInfo_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 LibraryInfo_STATUS instances for property testing - lazily instantiated by LibraryInfo_STATUSGenerator()
var libraryInfo_STATUSGenerator gopter.Gen

// LibraryInfo_STATUSGenerator returns a generator of LibraryInfo_STATUS instances for property testing.
func LibraryInfo_STATUSGenerator() gopter.Gen {
	if libraryInfo_STATUSGenerator != nil {
		return libraryInfo_STATUSGenerator
	}

	generators := make(map[string]gopter.Gen)
	AddIndependentPropertyGeneratorsForLibraryInfo_STATUS(generators)
	libraryInfo_STATUSGenerator = gen.Struct(reflect.TypeOf(LibraryInfo_STATUS{}), generators)

	return libraryInfo_STATUSGenerator
}

// AddIndependentPropertyGeneratorsForLibraryInfo_STATUS is a factory method for creating gopter generators
func AddIndependentPropertyGeneratorsForLibraryInfo_STATUS(gens map[string]gopter.Gen) {
	gens["ContainerName"] = gen.PtrOf(gen.AlphaString())
	gens["CreatorId"] = gen.PtrOf(gen.AlphaString())
	gens["Name"] = gen.PtrOf(gen.AlphaString())
	gens["Path"] = gen.PtrOf(gen.AlphaString())
	gens["ProvisioningStatus"] = gen.PtrOf(gen.AlphaString())
	gens["Type"] = gen.PtrOf(gen.AlphaString())
	gens["UploadedTimestamp"] = gen.PtrOf(gen.AlphaString())
}

func Test_LibraryRequirements_WhenPropertiesConverted_RoundTripsWithoutLoss(t *testing.T) {
	t.Parallel()
	parameters := gopter.DefaultTestParameters()
	parameters.MaxSize = 10
	properties := gopter.NewProperties(parameters)
	properties.Property(
		"Round trip from LibraryRequirements to LibraryRequirements via AssignProperties_To_LibraryRequirements & AssignProperties_From_LibraryRequirements returns original",
		prop.ForAll(RunPropertyAssignmentTestForLibraryRequirements, LibraryRequirementsGenerator()))
	properties.TestingRun(t, gopter.NewFormatedReporter(false, 240, os.Stdout))
}

// RunPropertyAssignmentTestForLibraryRequirements tests if a specific instance of LibraryRequirements can be assigned to storage and back losslessly
func RunPropertyAssignmentTestForLibraryRequirements(subject LibraryRequirements) string {
	// Copy subject to make sure assignment doesn't modify it
	copied := subject.DeepCopy()

	// Use AssignPropertiesTo() for the first stage of conversion
	var other storage.LibraryRequirements
	err := copied.AssignProperties_To_LibraryRequirements(&other)
	if err != nil {
		return err.Error()
	}

	// Use AssignPropertiesFrom() to convert back to our original type
	var actual LibraryRequirements
	err = actual.AssignProperties_From_LibraryRequirements(&other)
	if err != nil {
		return err.Error()
	}

	// Check for a match
	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 ""
}

func Test_LibraryRequirements_WhenSerializedToJson_DeserializesAsEqual(t *testing.T) {
	t.Parallel()
	parameters := gopter.DefaultTestParameters()
	parameters.MinSuccessfulTests = 100
	parameters.MaxSize = 3
	properties := gopter.NewProperties(parameters)
	properties.Property(
		"Round trip of LibraryRequirements via JSON returns original",
		prop.ForAll(RunJSONSerializationTestForLibraryRequirements, LibraryRequirementsGenerator()))
	properties.TestingRun(t, gopter.NewFormatedReporter(true, 240, os.Stdout))
}

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

	// Deserialize back into memory
	var actual LibraryRequirements
	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 LibraryRequirements instances for property testing - lazily instantiated by
// LibraryRequirementsGenerator()
var libraryRequirementsGenerator gopter.Gen

// LibraryRequirementsGenerator returns a generator of LibraryRequirements instances for property testing.
func LibraryRequirementsGenerator() gopter.Gen {
	if libraryRequirementsGenerator != nil {
		return libraryRequirementsGenerator
	}

	generators := make(map[string]gopter.Gen)
	AddIndependentPropertyGeneratorsForLibraryRequirements(generators)
	libraryRequirementsGenerator = gen.Struct(reflect.TypeOf(LibraryRequirements{}), generators)

	return libraryRequirementsGenerator
}

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

func Test_LibraryRequirements_STATUS_WhenPropertiesConverted_RoundTripsWithoutLoss(t *testing.T) {
	t.Parallel()
	parameters := gopter.DefaultTestParameters()
	parameters.MaxSize = 10
	properties := gopter.NewProperties(parameters)
	properties.Property(
		"Round trip from LibraryRequirements_STATUS to LibraryRequirements_STATUS via AssignProperties_To_LibraryRequirements_STATUS & AssignProperties_From_LibraryRequirements_STATUS returns original",
		prop.ForAll(RunPropertyAssignmentTestForLibraryRequirements_STATUS, LibraryRequirements_STATUSGenerator()))
	properties.TestingRun(t, gopter.NewFormatedReporter(false, 240, os.Stdout))
}

// RunPropertyAssignmentTestForLibraryRequirements_STATUS tests if a specific instance of LibraryRequirements_STATUS can be assigned to storage and back losslessly
func RunPropertyAssignmentTestForLibraryRequirements_STATUS(subject LibraryRequirements_STATUS) string {
	// Copy subject to make sure assignment doesn't modify it
	copied := subject.DeepCopy()

	// Use AssignPropertiesTo() for the first stage of conversion
	var other storage.LibraryRequirements_STATUS
	err := copied.AssignProperties_To_LibraryRequirements_STATUS(&other)
	if err != nil {
		return err.Error()
	}

	// Use AssignPropertiesFrom() to convert back to our original type
	var actual LibraryRequirements_STATUS
	err = actual.AssignProperties_From_LibraryRequirements_STATUS(&other)
	if err != nil {
		return err.Error()
	}

	// Check for a match
	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 ""
}

func Test_LibraryRequirements_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 LibraryRequirements_STATUS via JSON returns original",
		prop.ForAll(RunJSONSerializationTestForLibraryRequirements_STATUS, LibraryRequirements_STATUSGenerator()))
	properties.TestingRun(t, gopter.NewFormatedReporter(true, 240, os.Stdout))
}

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

	// Deserialize back into memory
	var actual LibraryRequirements_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 LibraryRequirements_STATUS instances for property testing - lazily instantiated by
// LibraryRequirements_STATUSGenerator()
var libraryRequirements_STATUSGenerator gopter.Gen

// LibraryRequirements_STATUSGenerator returns a generator of LibraryRequirements_STATUS instances for property testing.
func LibraryRequirements_STATUSGenerator() gopter.Gen {
	if libraryRequirements_STATUSGenerator != nil {
		return libraryRequirements_STATUSGenerator
	}

	generators := make(map[string]gopter.Gen)
	AddIndependentPropertyGeneratorsForLibraryRequirements_STATUS(generators)
	libraryRequirements_STATUSGenerator = gen.Struct(reflect.TypeOf(LibraryRequirements_STATUS{}), generators)

	return libraryRequirements_STATUSGenerator
}

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

func Test_SparkConfigProperties_WhenPropertiesConverted_RoundTripsWithoutLoss(t *testing.T) {
	t.Parallel()
	parameters := gopter.DefaultTestParameters()
	parameters.MaxSize = 10
	properties := gopter.NewProperties(parameters)
	properties.Property(
		"Round trip from SparkConfigProperties to SparkConfigProperties via AssignProperties_To_SparkConfigProperties & AssignProperties_From_SparkConfigProperties returns original",
		prop.ForAll(RunPropertyAssignmentTestForSparkConfigProperties, SparkConfigPropertiesGenerator()))
	properties.TestingRun(t, gopter.NewFormatedReporter(false, 240, os.Stdout))
}

// RunPropertyAssignmentTestForSparkConfigProperties tests if a specific instance of SparkConfigProperties can be assigned to storage and back losslessly
func RunPropertyAssignmentTestForSparkConfigProperties(subject SparkConfigProperties) string {
	// Copy subject to make sure assignment doesn't modify it
	copied := subject.DeepCopy()

	// Use AssignPropertiesTo() for the first stage of conversion
	var other storage.SparkConfigProperties
	err := copied.AssignProperties_To_SparkConfigProperties(&other)
	if err != nil {
		return err.Error()
	}

	// Use AssignPropertiesFrom() to convert back to our original type
	var actual SparkConfigProperties
	err = actual.AssignProperties_From_SparkConfigProperties(&other)
	if err != nil {
		return err.Error()
	}

	// Check for a match
	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 ""
}

func Test_SparkConfigProperties_WhenSerializedToJson_DeserializesAsEqual(t *testing.T) {
	t.Parallel()
	parameters := gopter.DefaultTestParameters()
	parameters.MinSuccessfulTests = 100
	parameters.MaxSize = 3
	properties := gopter.NewProperties(parameters)
	properties.Property(
		"Round trip of SparkConfigProperties via JSON returns original",
		prop.ForAll(RunJSONSerializationTestForSparkConfigProperties, SparkConfigPropertiesGenerator()))
	properties.TestingRun(t, gopter.NewFormatedReporter(true, 240, os.Stdout))
}

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

	// Deserialize back into memory
	var actual SparkConfigProperties
	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 SparkConfigProperties instances for property testing - lazily instantiated by
// SparkConfigPropertiesGenerator()
var sparkConfigPropertiesGenerator gopter.Gen

// SparkConfigPropertiesGenerator returns a generator of SparkConfigProperties instances for property testing.
func SparkConfigPropertiesGenerator() gopter.Gen {
	if sparkConfigPropertiesGenerator != nil {
		return sparkConfigPropertiesGenerator
	}

	generators := make(map[string]gopter.Gen)
	AddIndependentPropertyGeneratorsForSparkConfigProperties(generators)
	sparkConfigPropertiesGenerator = gen.Struct(reflect.TypeOf(SparkConfigProperties{}), generators)

	return sparkConfigPropertiesGenerator
}

// AddIndependentPropertyGeneratorsForSparkConfigProperties is a factory method for creating gopter generators
func AddIndependentPropertyGeneratorsForSparkConfigProperties(gens map[string]gopter.Gen) {
	gens["ConfigurationType"] = gen.PtrOf(gen.OneConstOf(SparkConfigProperties_ConfigurationType_Artifact, SparkConfigProperties_ConfigurationType_File))
	gens["Content"] = gen.PtrOf(gen.AlphaString())
	gens["Filename"] = gen.PtrOf(gen.AlphaString())
}

func Test_SparkConfigProperties_STATUS_WhenPropertiesConverted_RoundTripsWithoutLoss(t *testing.T) {
	t.Parallel()
	parameters := gopter.DefaultTestParameters()
	parameters.MaxSize = 10
	properties := gopter.NewProperties(parameters)
	properties.Property(
		"Round trip from SparkConfigProperties_STATUS to SparkConfigProperties_STATUS via AssignProperties_To_SparkConfigProperties_STATUS & AssignProperties_From_SparkConfigProperties_STATUS returns original",
		prop.ForAll(RunPropertyAssignmentTestForSparkConfigProperties_STATUS, SparkConfigProperties_STATUSGenerator()))
	properties.TestingRun(t, gopter.NewFormatedReporter(false, 240, os.Stdout))
}

// RunPropertyAssignmentTestForSparkConfigProperties_STATUS tests if a specific instance of SparkConfigProperties_STATUS can be assigned to storage and back losslessly
func RunPropertyAssignmentTestForSparkConfigProperties_STATUS(subject SparkConfigProperties_STATUS) string {
	// Copy subject to make sure assignment doesn't modify it
	copied := subject.DeepCopy()

	// Use AssignPropertiesTo() for the first stage of conversion
	var other storage.SparkConfigProperties_STATUS
	err := copied.AssignProperties_To_SparkConfigProperties_STATUS(&other)
	if err != nil {
		return err.Error()
	}

	// Use AssignPropertiesFrom() to convert back to our original type
	var actual SparkConfigProperties_STATUS
	err = actual.AssignProperties_From_SparkConfigProperties_STATUS(&other)
	if err != nil {
		return err.Error()
	}

	// Check for a match
	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 ""
}

func Test_SparkConfigProperties_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 SparkConfigProperties_STATUS via JSON returns original",
		prop.ForAll(RunJSONSerializationTestForSparkConfigProperties_STATUS, SparkConfigProperties_STATUSGenerator()))
	properties.TestingRun(t, gopter.NewFormatedReporter(true, 240, os.Stdout))
}

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

	// Deserialize back into memory
	var actual SparkConfigProperties_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 SparkConfigProperties_STATUS instances for property testing - lazily instantiated by
// SparkConfigProperties_STATUSGenerator()
var sparkConfigProperties_STATUSGenerator gopter.Gen

// SparkConfigProperties_STATUSGenerator returns a generator of SparkConfigProperties_STATUS instances for property testing.
func SparkConfigProperties_STATUSGenerator() gopter.Gen {
	if sparkConfigProperties_STATUSGenerator != nil {
		return sparkConfigProperties_STATUSGenerator
	}

	generators := make(map[string]gopter.Gen)
	AddIndependentPropertyGeneratorsForSparkConfigProperties_STATUS(generators)
	sparkConfigProperties_STATUSGenerator = gen.Struct(reflect.TypeOf(SparkConfigProperties_STATUS{}), generators)

	return sparkConfigProperties_STATUSGenerator
}

// AddIndependentPropertyGeneratorsForSparkConfigProperties_STATUS is a factory method for creating gopter generators
func AddIndependentPropertyGeneratorsForSparkConfigProperties_STATUS(gens map[string]gopter.Gen) {
	gens["ConfigurationType"] = gen.PtrOf(gen.OneConstOf(SparkConfigProperties_ConfigurationType_STATUS_Artifact, SparkConfigProperties_ConfigurationType_STATUS_File))
	gens["Content"] = gen.PtrOf(gen.AlphaString())
	gens["Filename"] = gen.PtrOf(gen.AlphaString())
	gens["Time"] = gen.PtrOf(gen.AlphaString())
}

func Test_WorkspacesBigDataPool_WhenConvertedToHub_RoundTripsWithoutLoss(t *testing.T) {
	t.Parallel()
	parameters := gopter.DefaultTestParameters()
	parameters.MaxSize = 10
	parameters.MinSuccessfulTests = 10
	properties := gopter.NewProperties(parameters)
	properties.Property(
		"Round trip from WorkspacesBigDataPool to hub returns original",
		prop.ForAll(RunResourceConversionTestForWorkspacesBigDataPool, WorkspacesBigDataPoolGenerator()))
	properties.TestingRun(t, gopter.NewFormatedReporter(false, 240, os.Stdout))
}

// RunResourceConversionTestForWorkspacesBigDataPool tests if a specific instance of WorkspacesBigDataPool round trips to the hub storage version and back losslessly
func RunResourceConversionTestForWorkspacesBigDataPool(subject WorkspacesBigDataPool) string {
	// Copy subject to make sure conversion doesn't modify it
	copied := subject.DeepCopy()

	// Convert to our hub version
	var hub storage.WorkspacesBigDataPool
	err := copied.ConvertTo(&hub)
	if err != nil {
		return err.Error()
	}

	// Convert from our hub version
	var actual WorkspacesBigDataPool
	err = actual.ConvertFrom(&hub)
	if err != nil {
		return err.Error()
	}

	// Compare actual with what we started with
	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 ""
}

func Test_WorkspacesBigDataPool_WhenPropertiesConverted_RoundTripsWithoutLoss(t *testing.T) {
	t.Parallel()
	parameters := gopter.DefaultTestParameters()
	parameters.MaxSize = 10
	properties := gopter.NewProperties(parameters)
	properties.Property(
		"Round trip from WorkspacesBigDataPool to WorkspacesBigDataPool via AssignProperties_To_WorkspacesBigDataPool & AssignProperties_From_WorkspacesBigDataPool returns original",
		prop.ForAll(RunPropertyAssignmentTestForWorkspacesBigDataPool, WorkspacesBigDataPoolGenerator()))
	properties.TestingRun(t, gopter.NewFormatedReporter(false, 240, os.Stdout))
}

// RunPropertyAssignmentTestForWorkspacesBigDataPool tests if a specific instance of WorkspacesBigDataPool can be assigned to storage and back losslessly
func RunPropertyAssignmentTestForWorkspacesBigDataPool(subject WorkspacesBigDataPool) string {
	// Copy subject to make sure assignment doesn't modify it
	copied := subject.DeepCopy()

	// Use AssignPropertiesTo() for the first stage of conversion
	var other storage.WorkspacesBigDataPool
	err := copied.AssignProperties_To_WorkspacesBigDataPool(&other)
	if err != nil {
		return err.Error()
	}

	// Use AssignPropertiesFrom() to convert back to our original type
	var actual WorkspacesBigDataPool
	err = actual.AssignProperties_From_WorkspacesBigDataPool(&other)
	if err != nil {
		return err.Error()
	}

	// Check for a match
	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 ""
}

func Test_WorkspacesBigDataPool_WhenSerializedToJson_DeserializesAsEqual(t *testing.T) {
	t.Parallel()
	parameters := gopter.DefaultTestParameters()
	parameters.MinSuccessfulTests = 20
	parameters.MaxSize = 3
	properties := gopter.NewProperties(parameters)
	properties.Property(
		"Round trip of WorkspacesBigDataPool via JSON returns original",
		prop.ForAll(RunJSONSerializationTestForWorkspacesBigDataPool, WorkspacesBigDataPoolGenerator()))
	properties.TestingRun(t, gopter.NewFormatedReporter(true, 240, os.Stdout))
}

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

	// Deserialize back into memory
	var actual WorkspacesBigDataPool
	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 WorkspacesBigDataPool instances for property testing - lazily instantiated by
// WorkspacesBigDataPoolGenerator()
var workspacesBigDataPoolGenerator gopter.Gen

// WorkspacesBigDataPoolGenerator returns a generator of WorkspacesBigDataPool instances for property testing.
func WorkspacesBigDataPoolGenerator() gopter.Gen {
	if workspacesBigDataPoolGenerator != nil {
		return workspacesBigDataPoolGenerator
	}

	generators := make(map[string]gopter.Gen)
	AddRelatedPropertyGeneratorsForWorkspacesBigDataPool(generators)
	workspacesBigDataPoolGenerator = gen.Struct(reflect.TypeOf(WorkspacesBigDataPool{}), generators)

	return workspacesBigDataPoolGenerator
}

// AddRelatedPropertyGeneratorsForWorkspacesBigDataPool is a factory method for creating gopter generators
func AddRelatedPropertyGeneratorsForWorkspacesBigDataPool(gens map[string]gopter.Gen) {
	gens["Spec"] = WorkspacesBigDataPool_SpecGenerator()
	gens["Status"] = WorkspacesBigDataPool_STATUSGenerator()
}

func Test_WorkspacesBigDataPoolOperatorSpec_WhenPropertiesConverted_RoundTripsWithoutLoss(t *testing.T) {
	t.Parallel()
	parameters := gopter.DefaultTestParameters()
	parameters.MaxSize = 10
	properties := gopter.NewProperties(parameters)
	properties.Property(
		"Round trip from WorkspacesBigDataPoolOperatorSpec to WorkspacesBigDataPoolOperatorSpec via AssignProperties_To_WorkspacesBigDataPoolOperatorSpec & AssignProperties_From_WorkspacesBigDataPoolOperatorSpec returns original",
		prop.ForAll(RunPropertyAssignmentTestForWorkspacesBigDataPoolOperatorSpec, WorkspacesBigDataPoolOperatorSpecGenerator()))
	properties.TestingRun(t, gopter.NewFormatedReporter(false, 240, os.Stdout))
}

// RunPropertyAssignmentTestForWorkspacesBigDataPoolOperatorSpec tests if a specific instance of WorkspacesBigDataPoolOperatorSpec can be assigned to storage and back losslessly
func RunPropertyAssignmentTestForWorkspacesBigDataPoolOperatorSpec(subject WorkspacesBigDataPoolOperatorSpec) string {
	// Copy subject to make sure assignment doesn't modify it
	copied := subject.DeepCopy()

	// Use AssignPropertiesTo() for the first stage of conversion
	var other storage.WorkspacesBigDataPoolOperatorSpec
	err := copied.AssignProperties_To_WorkspacesBigDataPoolOperatorSpec(&other)
	if err != nil {
		return err.Error()
	}

	// Use AssignPropertiesFrom() to convert back to our original type
	var actual WorkspacesBigDataPoolOperatorSpec
	err = actual.AssignProperties_From_WorkspacesBigDataPoolOperatorSpec(&other)
	if err != nil {
		return err.Error()
	}

	// Check for a match
	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 ""
}

func Test_WorkspacesBigDataPoolOperatorSpec_WhenSerializedToJson_DeserializesAsEqual(t *testing.T) {
	t.Parallel()
	parameters := gopter.DefaultTestParameters()
	parameters.MinSuccessfulTests = 100
	parameters.MaxSize = 3
	properties := gopter.NewProperties(parameters)
	properties.Property(
		"Round trip of WorkspacesBigDataPoolOperatorSpec via JSON returns original",
		prop.ForAll(RunJSONSerializationTestForWorkspacesBigDataPoolOperatorSpec, WorkspacesBigDataPoolOperatorSpecGenerator()))
	properties.TestingRun(t, gopter.NewFormatedReporter(true, 240, os.Stdout))
}

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

	// Deserialize back into memory
	var actual WorkspacesBigDataPoolOperatorSpec
	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 WorkspacesBigDataPoolOperatorSpec instances for property testing - lazily instantiated by
// WorkspacesBigDataPoolOperatorSpecGenerator()
var workspacesBigDataPoolOperatorSpecGenerator gopter.Gen

// WorkspacesBigDataPoolOperatorSpecGenerator returns a generator of WorkspacesBigDataPoolOperatorSpec instances for property testing.
func WorkspacesBigDataPoolOperatorSpecGenerator() gopter.Gen {
	if workspacesBigDataPoolOperatorSpecGenerator != nil {
		return workspacesBigDataPoolOperatorSpecGenerator
	}

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

	return workspacesBigDataPoolOperatorSpecGenerator
}

func Test_WorkspacesBigDataPool_STATUS_WhenPropertiesConverted_RoundTripsWithoutLoss(t *testing.T) {
	t.Parallel()
	parameters := gopter.DefaultTestParameters()
	parameters.MaxSize = 10
	properties := gopter.NewProperties(parameters)
	properties.Property(
		"Round trip from WorkspacesBigDataPool_STATUS to WorkspacesBigDataPool_STATUS via AssignProperties_To_WorkspacesBigDataPool_STATUS & AssignProperties_From_WorkspacesBigDataPool_STATUS returns original",
		prop.ForAll(RunPropertyAssignmentTestForWorkspacesBigDataPool_STATUS, WorkspacesBigDataPool_STATUSGenerator()))
	properties.TestingRun(t, gopter.NewFormatedReporter(false, 240, os.Stdout))
}

// RunPropertyAssignmentTestForWorkspacesBigDataPool_STATUS tests if a specific instance of WorkspacesBigDataPool_STATUS can be assigned to storage and back losslessly
func RunPropertyAssignmentTestForWorkspacesBigDataPool_STATUS(subject WorkspacesBigDataPool_STATUS) string {
	// Copy subject to make sure assignment doesn't modify it
	copied := subject.DeepCopy()

	// Use AssignPropertiesTo() for the first stage of conversion
	var other storage.WorkspacesBigDataPool_STATUS
	err := copied.AssignProperties_To_WorkspacesBigDataPool_STATUS(&other)
	if err != nil {
		return err.Error()
	}

	// Use AssignPropertiesFrom() to convert back to our original type
	var actual WorkspacesBigDataPool_STATUS
	err = actual.AssignProperties_From_WorkspacesBigDataPool_STATUS(&other)
	if err != nil {
		return err.Error()
	}

	// Check for a match
	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 ""
}

func Test_WorkspacesBigDataPool_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 WorkspacesBigDataPool_STATUS via JSON returns original",
		prop.ForAll(RunJSONSerializationTestForWorkspacesBigDataPool_STATUS, WorkspacesBigDataPool_STATUSGenerator()))
	properties.TestingRun(t, gopter.NewFormatedReporter(true, 240, os.Stdout))
}

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

	// Deserialize back into memory
	var actual WorkspacesBigDataPool_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 WorkspacesBigDataPool_STATUS instances for property testing - lazily instantiated by
// WorkspacesBigDataPool_STATUSGenerator()
var workspacesBigDataPool_STATUSGenerator gopter.Gen

// WorkspacesBigDataPool_STATUSGenerator returns a generator of WorkspacesBigDataPool_STATUS instances for property testing.
// We first initialize workspacesBigDataPool_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 WorkspacesBigDataPool_STATUSGenerator() gopter.Gen {
	if workspacesBigDataPool_STATUSGenerator != nil {
		return workspacesBigDataPool_STATUSGenerator
	}

	generators := make(map[string]gopter.Gen)
	AddIndependentPropertyGeneratorsForWorkspacesBigDataPool_STATUS(generators)
	workspacesBigDataPool_STATUSGenerator = gen.Struct(reflect.TypeOf(WorkspacesBigDataPool_STATUS{}), generators)

	// The above call to gen.Struct() captures the map, so create a new one
	generators = make(map[string]gopter.Gen)
	AddIndependentPropertyGeneratorsForWorkspacesBigDataPool_STATUS(generators)
	AddRelatedPropertyGeneratorsForWorkspacesBigDataPool_STATUS(generators)
	workspacesBigDataPool_STATUSGenerator = gen.Struct(reflect.TypeOf(WorkspacesBigDataPool_STATUS{}), generators)

	return workspacesBigDataPool_STATUSGenerator
}

// AddIndependentPropertyGeneratorsForWorkspacesBigDataPool_STATUS is a factory method for creating gopter generators
func AddIndependentPropertyGeneratorsForWorkspacesBigDataPool_STATUS(gens map[string]gopter.Gen) {
	gens["CacheSize"] = gen.PtrOf(gen.Int())
	gens["CreationDate"] = gen.PtrOf(gen.AlphaString())
	gens["DefaultSparkLogFolder"] = gen.PtrOf(gen.AlphaString())
	gens["Id"] = gen.PtrOf(gen.AlphaString())
	gens["IsAutotuneEnabled"] = gen.PtrOf(gen.Bool())
	gens["IsComputeIsolationEnabled"] = gen.PtrOf(gen.Bool())
	gens["LastSucceededTimestamp"] = gen.PtrOf(gen.AlphaString())
	gens["Location"] = gen.PtrOf(gen.AlphaString())
	gens["Name"] = gen.PtrOf(gen.AlphaString())
	gens["NodeCount"] = gen.PtrOf(gen.Int())
	gens["NodeSize"] = gen.PtrOf(gen.OneConstOf(
		BigDataPoolResourceProperties_NodeSize_STATUS_Large,
		BigDataPoolResourceProperties_NodeSize_STATUS_Medium,
		BigDataPoolResourceProperties_NodeSize_STATUS_None,
		BigDataPoolResourceProperties_NodeSize_STATUS_Small,
		BigDataPoolResourceProperties_NodeSize_STATUS_XLarge,
		BigDataPoolResourceProperties_NodeSize_STATUS_XXLarge,
		BigDataPoolResourceProperties_NodeSize_STATUS_XXXLarge))
	gens["NodeSizeFamily"] = gen.PtrOf(gen.OneConstOf(
		BigDataPoolResourceProperties_NodeSizeFamily_STATUS_HardwareAcceleratedFPGA,
		BigDataPoolResourceProperties_NodeSizeFamily_STATUS_HardwareAcceleratedGPU,
		BigDataPoolResourceProperties_NodeSizeFamily_STATUS_MemoryOptimized,
		BigDataPoolResourceProperties_NodeSizeFamily_STATUS_None))
	gens["ProvisioningState"] = gen.PtrOf(gen.AlphaString())
	gens["SessionLevelPackagesEnabled"] = gen.PtrOf(gen.Bool())
	gens["SparkEventsFolder"] = gen.PtrOf(gen.AlphaString())
	gens["SparkVersion"] = gen.PtrOf(gen.AlphaString())
	gens["Tags"] = gen.MapOf(
		gen.AlphaString(),
		gen.AlphaString())
	gens["Type"] = gen.PtrOf(gen.AlphaString())
}

// AddRelatedPropertyGeneratorsForWorkspacesBigDataPool_STATUS is a factory method for creating gopter generators
func AddRelatedPropertyGeneratorsForWorkspacesBigDataPool_STATUS(gens map[string]gopter.Gen) {
	gens["AutoPause"] = gen.PtrOf(AutoPauseProperties_STATUSGenerator())
	gens["AutoScale"] = gen.PtrOf(AutoScaleProperties_STATUSGenerator())
	gens["CustomLibraries"] = gen.SliceOf(LibraryInfo_STATUSGenerator())
	gens["DynamicExecutorAllocation"] = gen.PtrOf(DynamicExecutorAllocation_STATUSGenerator())
	gens["LibraryRequirements"] = gen.PtrOf(LibraryRequirements_STATUSGenerator())
	gens["SparkConfigProperties"] = gen.PtrOf(SparkConfigProperties_STATUSGenerator())
}

func Test_WorkspacesBigDataPool_Spec_WhenPropertiesConverted_RoundTripsWithoutLoss(t *testing.T) {
	t.Parallel()
	parameters := gopter.DefaultTestParameters()
	parameters.MaxSize = 10
	properties := gopter.NewProperties(parameters)
	properties.Property(
		"Round trip from WorkspacesBigDataPool_Spec to WorkspacesBigDataPool_Spec via AssignProperties_To_WorkspacesBigDataPool_Spec & AssignProperties_From_WorkspacesBigDataPool_Spec returns original",
		prop.ForAll(RunPropertyAssignmentTestForWorkspacesBigDataPool_Spec, WorkspacesBigDataPool_SpecGenerator()))
	properties.TestingRun(t, gopter.NewFormatedReporter(false, 240, os.Stdout))
}

// RunPropertyAssignmentTestForWorkspacesBigDataPool_Spec tests if a specific instance of WorkspacesBigDataPool_Spec can be assigned to storage and back losslessly
func RunPropertyAssignmentTestForWorkspacesBigDataPool_Spec(subject WorkspacesBigDataPool_Spec) string {
	// Copy subject to make sure assignment doesn't modify it
	copied := subject.DeepCopy()

	// Use AssignPropertiesTo() for the first stage of conversion
	var other storage.WorkspacesBigDataPool_Spec
	err := copied.AssignProperties_To_WorkspacesBigDataPool_Spec(&other)
	if err != nil {
		return err.Error()
	}

	// Use AssignPropertiesFrom() to convert back to our original type
	var actual WorkspacesBigDataPool_Spec
	err = actual.AssignProperties_From_WorkspacesBigDataPool_Spec(&other)
	if err != nil {
		return err.Error()
	}

	// Check for a match
	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 ""
}

func Test_WorkspacesBigDataPool_Spec_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 WorkspacesBigDataPool_Spec via JSON returns original",
		prop.ForAll(RunJSONSerializationTestForWorkspacesBigDataPool_Spec, WorkspacesBigDataPool_SpecGenerator()))
	properties.TestingRun(t, gopter.NewFormatedReporter(true, 240, os.Stdout))
}

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

	// Deserialize back into memory
	var actual WorkspacesBigDataPool_Spec
	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 WorkspacesBigDataPool_Spec instances for property testing - lazily instantiated by
// WorkspacesBigDataPool_SpecGenerator()
var workspacesBigDataPool_SpecGenerator gopter.Gen

// WorkspacesBigDataPool_SpecGenerator returns a generator of WorkspacesBigDataPool_Spec instances for property testing.
// We first initialize workspacesBigDataPool_SpecGenerator 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 WorkspacesBigDataPool_SpecGenerator() gopter.Gen {
	if workspacesBigDataPool_SpecGenerator != nil {
		return workspacesBigDataPool_SpecGenerator
	}

	generators := make(map[string]gopter.Gen)
	AddIndependentPropertyGeneratorsForWorkspacesBigDataPool_Spec(generators)
	workspacesBigDataPool_SpecGenerator = gen.Struct(reflect.TypeOf(WorkspacesBigDataPool_Spec{}), generators)

	// The above call to gen.Struct() captures the map, so create a new one
	generators = make(map[string]gopter.Gen)
	AddIndependentPropertyGeneratorsForWorkspacesBigDataPool_Spec(generators)
	AddRelatedPropertyGeneratorsForWorkspacesBigDataPool_Spec(generators)
	workspacesBigDataPool_SpecGenerator = gen.Struct(reflect.TypeOf(WorkspacesBigDataPool_Spec{}), generators)

	return workspacesBigDataPool_SpecGenerator
}

// AddIndependentPropertyGeneratorsForWorkspacesBigDataPool_Spec is a factory method for creating gopter generators
func AddIndependentPropertyGeneratorsForWorkspacesBigDataPool_Spec(gens map[string]gopter.Gen) {
	gens["AzureName"] = gen.AlphaString()
	gens["CacheSize"] = gen.PtrOf(gen.Int())
	gens["DefaultSparkLogFolder"] = gen.PtrOf(gen.AlphaString())
	gens["IsAutotuneEnabled"] = gen.PtrOf(gen.Bool())
	gens["IsComputeIsolationEnabled"] = gen.PtrOf(gen.Bool())
	gens["Location"] = gen.PtrOf(gen.AlphaString())
	gens["NodeCount"] = gen.PtrOf(gen.Int())
	gens["NodeSize"] = gen.PtrOf(gen.OneConstOf(
		BigDataPoolResourceProperties_NodeSize_Large,
		BigDataPoolResourceProperties_NodeSize_Medium,
		BigDataPoolResourceProperties_NodeSize_None,
		BigDataPoolResourceProperties_NodeSize_Small,
		BigDataPoolResourceProperties_NodeSize_XLarge,
		BigDataPoolResourceProperties_NodeSize_XXLarge,
		BigDataPoolResourceProperties_NodeSize_XXXLarge))
	gens["NodeSizeFamily"] = gen.PtrOf(gen.OneConstOf(
		BigDataPoolResourceProperties_NodeSizeFamily_HardwareAcceleratedFPGA,
		BigDataPoolResourceProperties_NodeSizeFamily_HardwareAcceleratedGPU,
		BigDataPoolResourceProperties_NodeSizeFamily_MemoryOptimized,
		BigDataPoolResourceProperties_NodeSizeFamily_None))
	gens["ProvisioningState"] = gen.PtrOf(gen.AlphaString())
	gens["SessionLevelPackagesEnabled"] = gen.PtrOf(gen.Bool())
	gens["SparkEventsFolder"] = gen.PtrOf(gen.AlphaString())
	gens["SparkVersion"] = gen.PtrOf(gen.AlphaString())
	gens["Tags"] = gen.MapOf(
		gen.AlphaString(),
		gen.AlphaString())
}

// AddRelatedPropertyGeneratorsForWorkspacesBigDataPool_Spec is a factory method for creating gopter generators
func AddRelatedPropertyGeneratorsForWorkspacesBigDataPool_Spec(gens map[string]gopter.Gen) {
	gens["AutoPause"] = gen.PtrOf(AutoPausePropertiesGenerator())
	gens["AutoScale"] = gen.PtrOf(AutoScalePropertiesGenerator())
	gens["CustomLibraries"] = gen.SliceOf(LibraryInfoGenerator())
	gens["DynamicExecutorAllocation"] = gen.PtrOf(DynamicExecutorAllocationGenerator())
	gens["LibraryRequirements"] = gen.PtrOf(LibraryRequirementsGenerator())
	gens["OperatorSpec"] = gen.PtrOf(WorkspacesBigDataPoolOperatorSpecGenerator())
	gens["SparkConfigProperties"] = gen.PtrOf(SparkConfigPropertiesGenerator())
}
