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

import (
	"encoding/json"
	storage "github.com/Azure/azure-service-operator/v2/api/network/v1api20240301/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_FrontendIPConfiguration_PrivateLinkService_SubResourceEmbedded_WhenPropertiesConverted_RoundTripsWithoutLoss(t *testing.T) {
	t.Parallel()
	parameters := gopter.DefaultTestParameters()
	parameters.MaxSize = 10
	properties := gopter.NewProperties(parameters)
	properties.Property(
		"Round trip from FrontendIPConfiguration_PrivateLinkService_SubResourceEmbedded to FrontendIPConfiguration_PrivateLinkService_SubResourceEmbedded via AssignProperties_To_FrontendIPConfiguration_PrivateLinkService_SubResourceEmbedded & AssignProperties_From_FrontendIPConfiguration_PrivateLinkService_SubResourceEmbedded returns original",
		prop.ForAll(RunPropertyAssignmentTestForFrontendIPConfiguration_PrivateLinkService_SubResourceEmbedded, FrontendIPConfiguration_PrivateLinkService_SubResourceEmbeddedGenerator()))
	properties.TestingRun(t, gopter.NewFormatedReporter(false, 240, os.Stdout))
}

// RunPropertyAssignmentTestForFrontendIPConfiguration_PrivateLinkService_SubResourceEmbedded tests if a specific instance of FrontendIPConfiguration_PrivateLinkService_SubResourceEmbedded can be assigned to storage and back losslessly
func RunPropertyAssignmentTestForFrontendIPConfiguration_PrivateLinkService_SubResourceEmbedded(subject FrontendIPConfiguration_PrivateLinkService_SubResourceEmbedded) 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.FrontendIPConfiguration_PrivateLinkService_SubResourceEmbedded
	err := copied.AssignProperties_To_FrontendIPConfiguration_PrivateLinkService_SubResourceEmbedded(&other)
	if err != nil {
		return err.Error()
	}

	// Use AssignPropertiesFrom() to convert back to our original type
	var actual FrontendIPConfiguration_PrivateLinkService_SubResourceEmbedded
	err = actual.AssignProperties_From_FrontendIPConfiguration_PrivateLinkService_SubResourceEmbedded(&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_FrontendIPConfiguration_PrivateLinkService_SubResourceEmbedded_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 FrontendIPConfiguration_PrivateLinkService_SubResourceEmbedded via JSON returns original",
		prop.ForAll(RunJSONSerializationTestForFrontendIPConfiguration_PrivateLinkService_SubResourceEmbedded, FrontendIPConfiguration_PrivateLinkService_SubResourceEmbeddedGenerator()))
	properties.TestingRun(t, gopter.NewFormatedReporter(true, 240, os.Stdout))
}

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

	// Deserialize back into memory
	var actual FrontendIPConfiguration_PrivateLinkService_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 FrontendIPConfiguration_PrivateLinkService_SubResourceEmbedded instances for property testing - lazily
// instantiated by FrontendIPConfiguration_PrivateLinkService_SubResourceEmbeddedGenerator()
var frontendIPConfiguration_PrivateLinkService_SubResourceEmbeddedGenerator gopter.Gen

// FrontendIPConfiguration_PrivateLinkService_SubResourceEmbeddedGenerator returns a generator of FrontendIPConfiguration_PrivateLinkService_SubResourceEmbedded instances for property testing.
func FrontendIPConfiguration_PrivateLinkService_SubResourceEmbeddedGenerator() gopter.Gen {
	if frontendIPConfiguration_PrivateLinkService_SubResourceEmbeddedGenerator != nil {
		return frontendIPConfiguration_PrivateLinkService_SubResourceEmbeddedGenerator
	}

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

	return frontendIPConfiguration_PrivateLinkService_SubResourceEmbeddedGenerator
}

func Test_FrontendIPConfiguration_STATUS_PrivateLinkService_SubResourceEmbedded_WhenPropertiesConverted_RoundTripsWithoutLoss(t *testing.T) {
	t.Parallel()
	parameters := gopter.DefaultTestParameters()
	parameters.MaxSize = 10
	properties := gopter.NewProperties(parameters)
	properties.Property(
		"Round trip from FrontendIPConfiguration_STATUS_PrivateLinkService_SubResourceEmbedded to FrontendIPConfiguration_STATUS_PrivateLinkService_SubResourceEmbedded via AssignProperties_To_FrontendIPConfiguration_STATUS_PrivateLinkService_SubResourceEmbedded & AssignProperties_From_FrontendIPConfiguration_STATUS_PrivateLinkService_SubResourceEmbedded returns original",
		prop.ForAll(RunPropertyAssignmentTestForFrontendIPConfiguration_STATUS_PrivateLinkService_SubResourceEmbedded, FrontendIPConfiguration_STATUS_PrivateLinkService_SubResourceEmbeddedGenerator()))
	properties.TestingRun(t, gopter.NewFormatedReporter(false, 240, os.Stdout))
}

// RunPropertyAssignmentTestForFrontendIPConfiguration_STATUS_PrivateLinkService_SubResourceEmbedded tests if a specific instance of FrontendIPConfiguration_STATUS_PrivateLinkService_SubResourceEmbedded can be assigned to storage and back losslessly
func RunPropertyAssignmentTestForFrontendIPConfiguration_STATUS_PrivateLinkService_SubResourceEmbedded(subject FrontendIPConfiguration_STATUS_PrivateLinkService_SubResourceEmbedded) 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.FrontendIPConfiguration_STATUS_PrivateLinkService_SubResourceEmbedded
	err := copied.AssignProperties_To_FrontendIPConfiguration_STATUS_PrivateLinkService_SubResourceEmbedded(&other)
	if err != nil {
		return err.Error()
	}

	// Use AssignPropertiesFrom() to convert back to our original type
	var actual FrontendIPConfiguration_STATUS_PrivateLinkService_SubResourceEmbedded
	err = actual.AssignProperties_From_FrontendIPConfiguration_STATUS_PrivateLinkService_SubResourceEmbedded(&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_FrontendIPConfiguration_STATUS_PrivateLinkService_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 FrontendIPConfiguration_STATUS_PrivateLinkService_SubResourceEmbedded via JSON returns original",
		prop.ForAll(RunJSONSerializationTestForFrontendIPConfiguration_STATUS_PrivateLinkService_SubResourceEmbedded, FrontendIPConfiguration_STATUS_PrivateLinkService_SubResourceEmbeddedGenerator()))
	properties.TestingRun(t, gopter.NewFormatedReporter(true, 240, os.Stdout))
}

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

	// Deserialize back into memory
	var actual FrontendIPConfiguration_STATUS_PrivateLinkService_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 FrontendIPConfiguration_STATUS_PrivateLinkService_SubResourceEmbedded instances for property testing -
// lazily instantiated by FrontendIPConfiguration_STATUS_PrivateLinkService_SubResourceEmbeddedGenerator()
var frontendIPConfiguration_STATUS_PrivateLinkService_SubResourceEmbeddedGenerator gopter.Gen

// FrontendIPConfiguration_STATUS_PrivateLinkService_SubResourceEmbeddedGenerator returns a generator of FrontendIPConfiguration_STATUS_PrivateLinkService_SubResourceEmbedded instances for property testing.
func FrontendIPConfiguration_STATUS_PrivateLinkService_SubResourceEmbeddedGenerator() gopter.Gen {
	if frontendIPConfiguration_STATUS_PrivateLinkService_SubResourceEmbeddedGenerator != nil {
		return frontendIPConfiguration_STATUS_PrivateLinkService_SubResourceEmbeddedGenerator
	}

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

	return frontendIPConfiguration_STATUS_PrivateLinkService_SubResourceEmbeddedGenerator
}

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

func Test_NetworkInterface_STATUS_PrivateLinkService_SubResourceEmbedded_WhenPropertiesConverted_RoundTripsWithoutLoss(t *testing.T) {
	t.Parallel()
	parameters := gopter.DefaultTestParameters()
	parameters.MaxSize = 10
	properties := gopter.NewProperties(parameters)
	properties.Property(
		"Round trip from NetworkInterface_STATUS_PrivateLinkService_SubResourceEmbedded to NetworkInterface_STATUS_PrivateLinkService_SubResourceEmbedded via AssignProperties_To_NetworkInterface_STATUS_PrivateLinkService_SubResourceEmbedded & AssignProperties_From_NetworkInterface_STATUS_PrivateLinkService_SubResourceEmbedded returns original",
		prop.ForAll(RunPropertyAssignmentTestForNetworkInterface_STATUS_PrivateLinkService_SubResourceEmbedded, NetworkInterface_STATUS_PrivateLinkService_SubResourceEmbeddedGenerator()))
	properties.TestingRun(t, gopter.NewFormatedReporter(false, 240, os.Stdout))
}

// RunPropertyAssignmentTestForNetworkInterface_STATUS_PrivateLinkService_SubResourceEmbedded tests if a specific instance of NetworkInterface_STATUS_PrivateLinkService_SubResourceEmbedded can be assigned to storage and back losslessly
func RunPropertyAssignmentTestForNetworkInterface_STATUS_PrivateLinkService_SubResourceEmbedded(subject NetworkInterface_STATUS_PrivateLinkService_SubResourceEmbedded) 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.NetworkInterface_STATUS_PrivateLinkService_SubResourceEmbedded
	err := copied.AssignProperties_To_NetworkInterface_STATUS_PrivateLinkService_SubResourceEmbedded(&other)
	if err != nil {
		return err.Error()
	}

	// Use AssignPropertiesFrom() to convert back to our original type
	var actual NetworkInterface_STATUS_PrivateLinkService_SubResourceEmbedded
	err = actual.AssignProperties_From_NetworkInterface_STATUS_PrivateLinkService_SubResourceEmbedded(&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_NetworkInterface_STATUS_PrivateLinkService_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 NetworkInterface_STATUS_PrivateLinkService_SubResourceEmbedded via JSON returns original",
		prop.ForAll(RunJSONSerializationTestForNetworkInterface_STATUS_PrivateLinkService_SubResourceEmbedded, NetworkInterface_STATUS_PrivateLinkService_SubResourceEmbeddedGenerator()))
	properties.TestingRun(t, gopter.NewFormatedReporter(true, 240, os.Stdout))
}

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

	// Deserialize back into memory
	var actual NetworkInterface_STATUS_PrivateLinkService_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 NetworkInterface_STATUS_PrivateLinkService_SubResourceEmbedded instances for property testing - lazily
// instantiated by NetworkInterface_STATUS_PrivateLinkService_SubResourceEmbeddedGenerator()
var networkInterface_STATUS_PrivateLinkService_SubResourceEmbeddedGenerator gopter.Gen

// NetworkInterface_STATUS_PrivateLinkService_SubResourceEmbeddedGenerator returns a generator of NetworkInterface_STATUS_PrivateLinkService_SubResourceEmbedded instances for property testing.
func NetworkInterface_STATUS_PrivateLinkService_SubResourceEmbeddedGenerator() gopter.Gen {
	if networkInterface_STATUS_PrivateLinkService_SubResourceEmbeddedGenerator != nil {
		return networkInterface_STATUS_PrivateLinkService_SubResourceEmbeddedGenerator
	}

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

	return networkInterface_STATUS_PrivateLinkService_SubResourceEmbeddedGenerator
}

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

func Test_PrivateEndpointConnection_STATUS_WhenPropertiesConverted_RoundTripsWithoutLoss(t *testing.T) {
	t.Parallel()
	parameters := gopter.DefaultTestParameters()
	parameters.MaxSize = 10
	properties := gopter.NewProperties(parameters)
	properties.Property(
		"Round trip from PrivateEndpointConnection_STATUS to PrivateEndpointConnection_STATUS via AssignProperties_To_PrivateEndpointConnection_STATUS & AssignProperties_From_PrivateEndpointConnection_STATUS returns original",
		prop.ForAll(RunPropertyAssignmentTestForPrivateEndpointConnection_STATUS, PrivateEndpointConnection_STATUSGenerator()))
	properties.TestingRun(t, gopter.NewFormatedReporter(false, 240, os.Stdout))
}

// RunPropertyAssignmentTestForPrivateEndpointConnection_STATUS tests if a specific instance of PrivateEndpointConnection_STATUS can be assigned to storage and back losslessly
func RunPropertyAssignmentTestForPrivateEndpointConnection_STATUS(subject PrivateEndpointConnection_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.PrivateEndpointConnection_STATUS
	err := copied.AssignProperties_To_PrivateEndpointConnection_STATUS(&other)
	if err != nil {
		return err.Error()
	}

	// Use AssignPropertiesFrom() to convert back to our original type
	var actual PrivateEndpointConnection_STATUS
	err = actual.AssignProperties_From_PrivateEndpointConnection_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_PrivateEndpointConnection_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 PrivateEndpointConnection_STATUS via JSON returns original",
		prop.ForAll(RunJSONSerializationTestForPrivateEndpointConnection_STATUS, PrivateEndpointConnection_STATUSGenerator()))
	properties.TestingRun(t, gopter.NewFormatedReporter(true, 240, os.Stdout))
}

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

	// Deserialize back into memory
	var actual PrivateEndpointConnection_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 PrivateEndpointConnection_STATUS instances for property testing - lazily instantiated by
// PrivateEndpointConnection_STATUSGenerator()
var privateEndpointConnection_STATUSGenerator gopter.Gen

// PrivateEndpointConnection_STATUSGenerator returns a generator of PrivateEndpointConnection_STATUS instances for property testing.
func PrivateEndpointConnection_STATUSGenerator() gopter.Gen {
	if privateEndpointConnection_STATUSGenerator != nil {
		return privateEndpointConnection_STATUSGenerator
	}

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

	return privateEndpointConnection_STATUSGenerator
}

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

func Test_PrivateLinkService_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 PrivateLinkService to hub returns original",
		prop.ForAll(RunResourceConversionTestForPrivateLinkService, PrivateLinkServiceGenerator()))
	properties.TestingRun(t, gopter.NewFormatedReporter(false, 240, os.Stdout))
}

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

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

	// Convert from our hub version
	var actual PrivateLinkService
	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_PrivateLinkService_WhenPropertiesConverted_RoundTripsWithoutLoss(t *testing.T) {
	t.Parallel()
	parameters := gopter.DefaultTestParameters()
	parameters.MaxSize = 10
	properties := gopter.NewProperties(parameters)
	properties.Property(
		"Round trip from PrivateLinkService to PrivateLinkService via AssignProperties_To_PrivateLinkService & AssignProperties_From_PrivateLinkService returns original",
		prop.ForAll(RunPropertyAssignmentTestForPrivateLinkService, PrivateLinkServiceGenerator()))
	properties.TestingRun(t, gopter.NewFormatedReporter(false, 240, os.Stdout))
}

// RunPropertyAssignmentTestForPrivateLinkService tests if a specific instance of PrivateLinkService can be assigned to storage and back losslessly
func RunPropertyAssignmentTestForPrivateLinkService(subject PrivateLinkService) 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.PrivateLinkService
	err := copied.AssignProperties_To_PrivateLinkService(&other)
	if err != nil {
		return err.Error()
	}

	// Use AssignPropertiesFrom() to convert back to our original type
	var actual PrivateLinkService
	err = actual.AssignProperties_From_PrivateLinkService(&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_PrivateLinkService_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 PrivateLinkService via JSON returns original",
		prop.ForAll(RunJSONSerializationTestForPrivateLinkService, PrivateLinkServiceGenerator()))
	properties.TestingRun(t, gopter.NewFormatedReporter(true, 240, os.Stdout))
}

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

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

// PrivateLinkServiceGenerator returns a generator of PrivateLinkService instances for property testing.
func PrivateLinkServiceGenerator() gopter.Gen {
	if privateLinkServiceGenerator != nil {
		return privateLinkServiceGenerator
	}

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

	return privateLinkServiceGenerator
}

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

func Test_PrivateLinkServiceIpConfiguration_WhenPropertiesConverted_RoundTripsWithoutLoss(t *testing.T) {
	t.Parallel()
	parameters := gopter.DefaultTestParameters()
	parameters.MaxSize = 10
	properties := gopter.NewProperties(parameters)
	properties.Property(
		"Round trip from PrivateLinkServiceIpConfiguration to PrivateLinkServiceIpConfiguration via AssignProperties_To_PrivateLinkServiceIpConfiguration & AssignProperties_From_PrivateLinkServiceIpConfiguration returns original",
		prop.ForAll(RunPropertyAssignmentTestForPrivateLinkServiceIpConfiguration, PrivateLinkServiceIpConfigurationGenerator()))
	properties.TestingRun(t, gopter.NewFormatedReporter(false, 240, os.Stdout))
}

// RunPropertyAssignmentTestForPrivateLinkServiceIpConfiguration tests if a specific instance of PrivateLinkServiceIpConfiguration can be assigned to storage and back losslessly
func RunPropertyAssignmentTestForPrivateLinkServiceIpConfiguration(subject PrivateLinkServiceIpConfiguration) 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.PrivateLinkServiceIpConfiguration
	err := copied.AssignProperties_To_PrivateLinkServiceIpConfiguration(&other)
	if err != nil {
		return err.Error()
	}

	// Use AssignPropertiesFrom() to convert back to our original type
	var actual PrivateLinkServiceIpConfiguration
	err = actual.AssignProperties_From_PrivateLinkServiceIpConfiguration(&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_PrivateLinkServiceIpConfiguration_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 PrivateLinkServiceIpConfiguration via JSON returns original",
		prop.ForAll(RunJSONSerializationTestForPrivateLinkServiceIpConfiguration, PrivateLinkServiceIpConfigurationGenerator()))
	properties.TestingRun(t, gopter.NewFormatedReporter(true, 240, os.Stdout))
}

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

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

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

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

	// The above call to gen.Struct() captures the map, so create a new one
	generators = make(map[string]gopter.Gen)
	AddIndependentPropertyGeneratorsForPrivateLinkServiceIpConfiguration(generators)
	AddRelatedPropertyGeneratorsForPrivateLinkServiceIpConfiguration(generators)
	privateLinkServiceIpConfigurationGenerator = gen.Struct(reflect.TypeOf(PrivateLinkServiceIpConfiguration{}), generators)

	return privateLinkServiceIpConfigurationGenerator
}

// AddIndependentPropertyGeneratorsForPrivateLinkServiceIpConfiguration is a factory method for creating gopter generators
func AddIndependentPropertyGeneratorsForPrivateLinkServiceIpConfiguration(gens map[string]gopter.Gen) {
	gens["Name"] = gen.PtrOf(gen.AlphaString())
	gens["Primary"] = gen.PtrOf(gen.Bool())
	gens["PrivateIPAddress"] = gen.PtrOf(gen.AlphaString())
	gens["PrivateIPAddressVersion"] = gen.PtrOf(gen.OneConstOf(IPVersion_IPv4, IPVersion_IPv6))
	gens["PrivateIPAllocationMethod"] = gen.PtrOf(gen.OneConstOf(IPAllocationMethod_Dynamic, IPAllocationMethod_Static))
}

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

func Test_PrivateLinkServiceIpConfiguration_STATUS_WhenPropertiesConverted_RoundTripsWithoutLoss(t *testing.T) {
	t.Parallel()
	parameters := gopter.DefaultTestParameters()
	parameters.MaxSize = 10
	properties := gopter.NewProperties(parameters)
	properties.Property(
		"Round trip from PrivateLinkServiceIpConfiguration_STATUS to PrivateLinkServiceIpConfiguration_STATUS via AssignProperties_To_PrivateLinkServiceIpConfiguration_STATUS & AssignProperties_From_PrivateLinkServiceIpConfiguration_STATUS returns original",
		prop.ForAll(RunPropertyAssignmentTestForPrivateLinkServiceIpConfiguration_STATUS, PrivateLinkServiceIpConfiguration_STATUSGenerator()))
	properties.TestingRun(t, gopter.NewFormatedReporter(false, 240, os.Stdout))
}

// RunPropertyAssignmentTestForPrivateLinkServiceIpConfiguration_STATUS tests if a specific instance of PrivateLinkServiceIpConfiguration_STATUS can be assigned to storage and back losslessly
func RunPropertyAssignmentTestForPrivateLinkServiceIpConfiguration_STATUS(subject PrivateLinkServiceIpConfiguration_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.PrivateLinkServiceIpConfiguration_STATUS
	err := copied.AssignProperties_To_PrivateLinkServiceIpConfiguration_STATUS(&other)
	if err != nil {
		return err.Error()
	}

	// Use AssignPropertiesFrom() to convert back to our original type
	var actual PrivateLinkServiceIpConfiguration_STATUS
	err = actual.AssignProperties_From_PrivateLinkServiceIpConfiguration_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_PrivateLinkServiceIpConfiguration_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 PrivateLinkServiceIpConfiguration_STATUS via JSON returns original",
		prop.ForAll(RunJSONSerializationTestForPrivateLinkServiceIpConfiguration_STATUS, PrivateLinkServiceIpConfiguration_STATUSGenerator()))
	properties.TestingRun(t, gopter.NewFormatedReporter(true, 240, os.Stdout))
}

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

	// Deserialize back into memory
	var actual PrivateLinkServiceIpConfiguration_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 PrivateLinkServiceIpConfiguration_STATUS instances for property testing - lazily instantiated by
// PrivateLinkServiceIpConfiguration_STATUSGenerator()
var privateLinkServiceIpConfiguration_STATUSGenerator gopter.Gen

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

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

	// The above call to gen.Struct() captures the map, so create a new one
	generators = make(map[string]gopter.Gen)
	AddIndependentPropertyGeneratorsForPrivateLinkServiceIpConfiguration_STATUS(generators)
	AddRelatedPropertyGeneratorsForPrivateLinkServiceIpConfiguration_STATUS(generators)
	privateLinkServiceIpConfiguration_STATUSGenerator = gen.Struct(reflect.TypeOf(PrivateLinkServiceIpConfiguration_STATUS{}), generators)

	return privateLinkServiceIpConfiguration_STATUSGenerator
}

// AddIndependentPropertyGeneratorsForPrivateLinkServiceIpConfiguration_STATUS is a factory method for creating gopter generators
func AddIndependentPropertyGeneratorsForPrivateLinkServiceIpConfiguration_STATUS(gens map[string]gopter.Gen) {
	gens["Etag"] = gen.PtrOf(gen.AlphaString())
	gens["Id"] = gen.PtrOf(gen.AlphaString())
	gens["Name"] = gen.PtrOf(gen.AlphaString())
	gens["Primary"] = gen.PtrOf(gen.Bool())
	gens["PrivateIPAddress"] = gen.PtrOf(gen.AlphaString())
	gens["PrivateIPAddressVersion"] = gen.PtrOf(gen.OneConstOf(IPVersion_STATUS_IPv4, IPVersion_STATUS_IPv6))
	gens["PrivateIPAllocationMethod"] = gen.PtrOf(gen.OneConstOf(IPAllocationMethod_STATUS_Dynamic, IPAllocationMethod_STATUS_Static))
	gens["ProvisioningState"] = gen.PtrOf(gen.OneConstOf(
		ProvisioningState_STATUS_Deleting,
		ProvisioningState_STATUS_Failed,
		ProvisioningState_STATUS_Succeeded,
		ProvisioningState_STATUS_Updating))
	gens["Type"] = gen.PtrOf(gen.AlphaString())
}

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

func Test_PrivateLinkServiceOperatorConfigMaps_WhenPropertiesConverted_RoundTripsWithoutLoss(t *testing.T) {
	t.Parallel()
	parameters := gopter.DefaultTestParameters()
	parameters.MaxSize = 10
	properties := gopter.NewProperties(parameters)
	properties.Property(
		"Round trip from PrivateLinkServiceOperatorConfigMaps to PrivateLinkServiceOperatorConfigMaps via AssignProperties_To_PrivateLinkServiceOperatorConfigMaps & AssignProperties_From_PrivateLinkServiceOperatorConfigMaps returns original",
		prop.ForAll(RunPropertyAssignmentTestForPrivateLinkServiceOperatorConfigMaps, PrivateLinkServiceOperatorConfigMapsGenerator()))
	properties.TestingRun(t, gopter.NewFormatedReporter(false, 240, os.Stdout))
}

// RunPropertyAssignmentTestForPrivateLinkServiceOperatorConfigMaps tests if a specific instance of PrivateLinkServiceOperatorConfigMaps can be assigned to storage and back losslessly
func RunPropertyAssignmentTestForPrivateLinkServiceOperatorConfigMaps(subject PrivateLinkServiceOperatorConfigMaps) 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.PrivateLinkServiceOperatorConfigMaps
	err := copied.AssignProperties_To_PrivateLinkServiceOperatorConfigMaps(&other)
	if err != nil {
		return err.Error()
	}

	// Use AssignPropertiesFrom() to convert back to our original type
	var actual PrivateLinkServiceOperatorConfigMaps
	err = actual.AssignProperties_From_PrivateLinkServiceOperatorConfigMaps(&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_PrivateLinkServiceOperatorConfigMaps_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 PrivateLinkServiceOperatorConfigMaps via JSON returns original",
		prop.ForAll(RunJSONSerializationTestForPrivateLinkServiceOperatorConfigMaps, PrivateLinkServiceOperatorConfigMapsGenerator()))
	properties.TestingRun(t, gopter.NewFormatedReporter(true, 240, os.Stdout))
}

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

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

// PrivateLinkServiceOperatorConfigMapsGenerator returns a generator of PrivateLinkServiceOperatorConfigMaps instances for property testing.
func PrivateLinkServiceOperatorConfigMapsGenerator() gopter.Gen {
	if privateLinkServiceOperatorConfigMapsGenerator != nil {
		return privateLinkServiceOperatorConfigMapsGenerator
	}

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

	return privateLinkServiceOperatorConfigMapsGenerator
}

func Test_PrivateLinkServiceOperatorSpec_WhenPropertiesConverted_RoundTripsWithoutLoss(t *testing.T) {
	t.Parallel()
	parameters := gopter.DefaultTestParameters()
	parameters.MaxSize = 10
	properties := gopter.NewProperties(parameters)
	properties.Property(
		"Round trip from PrivateLinkServiceOperatorSpec to PrivateLinkServiceOperatorSpec via AssignProperties_To_PrivateLinkServiceOperatorSpec & AssignProperties_From_PrivateLinkServiceOperatorSpec returns original",
		prop.ForAll(RunPropertyAssignmentTestForPrivateLinkServiceOperatorSpec, PrivateLinkServiceOperatorSpecGenerator()))
	properties.TestingRun(t, gopter.NewFormatedReporter(false, 240, os.Stdout))
}

// RunPropertyAssignmentTestForPrivateLinkServiceOperatorSpec tests if a specific instance of PrivateLinkServiceOperatorSpec can be assigned to storage and back losslessly
func RunPropertyAssignmentTestForPrivateLinkServiceOperatorSpec(subject PrivateLinkServiceOperatorSpec) 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.PrivateLinkServiceOperatorSpec
	err := copied.AssignProperties_To_PrivateLinkServiceOperatorSpec(&other)
	if err != nil {
		return err.Error()
	}

	// Use AssignPropertiesFrom() to convert back to our original type
	var actual PrivateLinkServiceOperatorSpec
	err = actual.AssignProperties_From_PrivateLinkServiceOperatorSpec(&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_PrivateLinkServiceOperatorSpec_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 PrivateLinkServiceOperatorSpec via JSON returns original",
		prop.ForAll(RunJSONSerializationTestForPrivateLinkServiceOperatorSpec, PrivateLinkServiceOperatorSpecGenerator()))
	properties.TestingRun(t, gopter.NewFormatedReporter(true, 240, os.Stdout))
}

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

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

// PrivateLinkServiceOperatorSpecGenerator returns a generator of PrivateLinkServiceOperatorSpec instances for property testing.
func PrivateLinkServiceOperatorSpecGenerator() gopter.Gen {
	if privateLinkServiceOperatorSpecGenerator != nil {
		return privateLinkServiceOperatorSpecGenerator
	}

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

	return privateLinkServiceOperatorSpecGenerator
}

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

func Test_PrivateLinkService_STATUS_WhenPropertiesConverted_RoundTripsWithoutLoss(t *testing.T) {
	t.Parallel()
	parameters := gopter.DefaultTestParameters()
	parameters.MaxSize = 10
	properties := gopter.NewProperties(parameters)
	properties.Property(
		"Round trip from PrivateLinkService_STATUS to PrivateLinkService_STATUS via AssignProperties_To_PrivateLinkService_STATUS & AssignProperties_From_PrivateLinkService_STATUS returns original",
		prop.ForAll(RunPropertyAssignmentTestForPrivateLinkService_STATUS, PrivateLinkService_STATUSGenerator()))
	properties.TestingRun(t, gopter.NewFormatedReporter(false, 240, os.Stdout))
}

// RunPropertyAssignmentTestForPrivateLinkService_STATUS tests if a specific instance of PrivateLinkService_STATUS can be assigned to storage and back losslessly
func RunPropertyAssignmentTestForPrivateLinkService_STATUS(subject PrivateLinkService_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.PrivateLinkService_STATUS
	err := copied.AssignProperties_To_PrivateLinkService_STATUS(&other)
	if err != nil {
		return err.Error()
	}

	// Use AssignPropertiesFrom() to convert back to our original type
	var actual PrivateLinkService_STATUS
	err = actual.AssignProperties_From_PrivateLinkService_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_PrivateLinkService_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 PrivateLinkService_STATUS via JSON returns original",
		prop.ForAll(RunJSONSerializationTestForPrivateLinkService_STATUS, PrivateLinkService_STATUSGenerator()))
	properties.TestingRun(t, gopter.NewFormatedReporter(true, 240, os.Stdout))
}

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

	// Deserialize back into memory
	var actual PrivateLinkService_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 PrivateLinkService_STATUS instances for property testing - lazily instantiated by
// PrivateLinkService_STATUSGenerator()
var privateLinkService_STATUSGenerator gopter.Gen

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

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

	// The above call to gen.Struct() captures the map, so create a new one
	generators = make(map[string]gopter.Gen)
	AddIndependentPropertyGeneratorsForPrivateLinkService_STATUS(generators)
	AddRelatedPropertyGeneratorsForPrivateLinkService_STATUS(generators)
	privateLinkService_STATUSGenerator = gen.Struct(reflect.TypeOf(PrivateLinkService_STATUS{}), generators)

	return privateLinkService_STATUSGenerator
}

// AddIndependentPropertyGeneratorsForPrivateLinkService_STATUS is a factory method for creating gopter generators
func AddIndependentPropertyGeneratorsForPrivateLinkService_STATUS(gens map[string]gopter.Gen) {
	gens["Alias"] = gen.PtrOf(gen.AlphaString())
	gens["DestinationIPAddress"] = gen.PtrOf(gen.AlphaString())
	gens["EnableProxyProtocol"] = gen.PtrOf(gen.Bool())
	gens["Etag"] = gen.PtrOf(gen.AlphaString())
	gens["Fqdns"] = gen.SliceOf(gen.AlphaString())
	gens["Id"] = gen.PtrOf(gen.AlphaString())
	gens["Location"] = gen.PtrOf(gen.AlphaString())
	gens["Name"] = gen.PtrOf(gen.AlphaString())
	gens["ProvisioningState"] = gen.PtrOf(gen.OneConstOf(
		ProvisioningState_STATUS_Deleting,
		ProvisioningState_STATUS_Failed,
		ProvisioningState_STATUS_Succeeded,
		ProvisioningState_STATUS_Updating))
	gens["Tags"] = gen.MapOf(
		gen.AlphaString(),
		gen.AlphaString())
	gens["Type"] = gen.PtrOf(gen.AlphaString())
}

// AddRelatedPropertyGeneratorsForPrivateLinkService_STATUS is a factory method for creating gopter generators
func AddRelatedPropertyGeneratorsForPrivateLinkService_STATUS(gens map[string]gopter.Gen) {
	gens["AutoApproval"] = gen.PtrOf(ResourceSet_STATUSGenerator())
	gens["ExtendedLocation"] = gen.PtrOf(ExtendedLocation_STATUSGenerator())
	gens["IpConfigurations"] = gen.SliceOf(PrivateLinkServiceIpConfiguration_STATUSGenerator())
	gens["LoadBalancerFrontendIpConfigurations"] = gen.SliceOf(FrontendIPConfiguration_STATUS_PrivateLinkService_SubResourceEmbeddedGenerator())
	gens["NetworkInterfaces"] = gen.SliceOf(NetworkInterface_STATUS_PrivateLinkService_SubResourceEmbeddedGenerator())
	gens["PrivateEndpointConnections"] = gen.SliceOf(PrivateEndpointConnection_STATUSGenerator())
	gens["Visibility"] = gen.PtrOf(ResourceSet_STATUSGenerator())
}

func Test_PrivateLinkService_Spec_WhenPropertiesConverted_RoundTripsWithoutLoss(t *testing.T) {
	t.Parallel()
	parameters := gopter.DefaultTestParameters()
	parameters.MaxSize = 10
	properties := gopter.NewProperties(parameters)
	properties.Property(
		"Round trip from PrivateLinkService_Spec to PrivateLinkService_Spec via AssignProperties_To_PrivateLinkService_Spec & AssignProperties_From_PrivateLinkService_Spec returns original",
		prop.ForAll(RunPropertyAssignmentTestForPrivateLinkService_Spec, PrivateLinkService_SpecGenerator()))
	properties.TestingRun(t, gopter.NewFormatedReporter(false, 240, os.Stdout))
}

// RunPropertyAssignmentTestForPrivateLinkService_Spec tests if a specific instance of PrivateLinkService_Spec can be assigned to storage and back losslessly
func RunPropertyAssignmentTestForPrivateLinkService_Spec(subject PrivateLinkService_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.PrivateLinkService_Spec
	err := copied.AssignProperties_To_PrivateLinkService_Spec(&other)
	if err != nil {
		return err.Error()
	}

	// Use AssignPropertiesFrom() to convert back to our original type
	var actual PrivateLinkService_Spec
	err = actual.AssignProperties_From_PrivateLinkService_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_PrivateLinkService_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 PrivateLinkService_Spec via JSON returns original",
		prop.ForAll(RunJSONSerializationTestForPrivateLinkService_Spec, PrivateLinkService_SpecGenerator()))
	properties.TestingRun(t, gopter.NewFormatedReporter(true, 240, os.Stdout))
}

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

	// Deserialize back into memory
	var actual PrivateLinkService_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 PrivateLinkService_Spec instances for property testing - lazily instantiated by
// PrivateLinkService_SpecGenerator()
var privateLinkService_SpecGenerator gopter.Gen

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

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

	// The above call to gen.Struct() captures the map, so create a new one
	generators = make(map[string]gopter.Gen)
	AddIndependentPropertyGeneratorsForPrivateLinkService_Spec(generators)
	AddRelatedPropertyGeneratorsForPrivateLinkService_Spec(generators)
	privateLinkService_SpecGenerator = gen.Struct(reflect.TypeOf(PrivateLinkService_Spec{}), generators)

	return privateLinkService_SpecGenerator
}

// AddIndependentPropertyGeneratorsForPrivateLinkService_Spec is a factory method for creating gopter generators
func AddIndependentPropertyGeneratorsForPrivateLinkService_Spec(gens map[string]gopter.Gen) {
	gens["AzureName"] = gen.AlphaString()
	gens["DestinationIPAddress"] = gen.PtrOf(gen.AlphaString())
	gens["EnableProxyProtocol"] = gen.PtrOf(gen.Bool())
	gens["Fqdns"] = gen.SliceOf(gen.AlphaString())
	gens["Location"] = gen.PtrOf(gen.AlphaString())
	gens["Tags"] = gen.MapOf(
		gen.AlphaString(),
		gen.AlphaString())
}

// AddRelatedPropertyGeneratorsForPrivateLinkService_Spec is a factory method for creating gopter generators
func AddRelatedPropertyGeneratorsForPrivateLinkService_Spec(gens map[string]gopter.Gen) {
	gens["AutoApproval"] = gen.PtrOf(ResourceSetGenerator())
	gens["ExtendedLocation"] = gen.PtrOf(ExtendedLocationGenerator())
	gens["IpConfigurations"] = gen.SliceOf(PrivateLinkServiceIpConfigurationGenerator())
	gens["LoadBalancerFrontendIpConfigurations"] = gen.SliceOf(FrontendIPConfiguration_PrivateLinkService_SubResourceEmbeddedGenerator())
	gens["OperatorSpec"] = gen.PtrOf(PrivateLinkServiceOperatorSpecGenerator())
	gens["Visibility"] = gen.PtrOf(ResourceSetGenerator())
}

func Test_ResourceSet_WhenPropertiesConverted_RoundTripsWithoutLoss(t *testing.T) {
	t.Parallel()
	parameters := gopter.DefaultTestParameters()
	parameters.MaxSize = 10
	properties := gopter.NewProperties(parameters)
	properties.Property(
		"Round trip from ResourceSet to ResourceSet via AssignProperties_To_ResourceSet & AssignProperties_From_ResourceSet returns original",
		prop.ForAll(RunPropertyAssignmentTestForResourceSet, ResourceSetGenerator()))
	properties.TestingRun(t, gopter.NewFormatedReporter(false, 240, os.Stdout))
}

// RunPropertyAssignmentTestForResourceSet tests if a specific instance of ResourceSet can be assigned to storage and back losslessly
func RunPropertyAssignmentTestForResourceSet(subject ResourceSet) 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.ResourceSet
	err := copied.AssignProperties_To_ResourceSet(&other)
	if err != nil {
		return err.Error()
	}

	// Use AssignPropertiesFrom() to convert back to our original type
	var actual ResourceSet
	err = actual.AssignProperties_From_ResourceSet(&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_ResourceSet_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 ResourceSet via JSON returns original",
		prop.ForAll(RunJSONSerializationTestForResourceSet, ResourceSetGenerator()))
	properties.TestingRun(t, gopter.NewFormatedReporter(true, 240, os.Stdout))
}

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

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

// ResourceSetGenerator returns a generator of ResourceSet instances for property testing.
func ResourceSetGenerator() gopter.Gen {
	if resourceSetGenerator != nil {
		return resourceSetGenerator
	}

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

	return resourceSetGenerator
}

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

func Test_ResourceSet_STATUS_WhenPropertiesConverted_RoundTripsWithoutLoss(t *testing.T) {
	t.Parallel()
	parameters := gopter.DefaultTestParameters()
	parameters.MaxSize = 10
	properties := gopter.NewProperties(parameters)
	properties.Property(
		"Round trip from ResourceSet_STATUS to ResourceSet_STATUS via AssignProperties_To_ResourceSet_STATUS & AssignProperties_From_ResourceSet_STATUS returns original",
		prop.ForAll(RunPropertyAssignmentTestForResourceSet_STATUS, ResourceSet_STATUSGenerator()))
	properties.TestingRun(t, gopter.NewFormatedReporter(false, 240, os.Stdout))
}

// RunPropertyAssignmentTestForResourceSet_STATUS tests if a specific instance of ResourceSet_STATUS can be assigned to storage and back losslessly
func RunPropertyAssignmentTestForResourceSet_STATUS(subject ResourceSet_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.ResourceSet_STATUS
	err := copied.AssignProperties_To_ResourceSet_STATUS(&other)
	if err != nil {
		return err.Error()
	}

	// Use AssignPropertiesFrom() to convert back to our original type
	var actual ResourceSet_STATUS
	err = actual.AssignProperties_From_ResourceSet_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_ResourceSet_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 ResourceSet_STATUS via JSON returns original",
		prop.ForAll(RunJSONSerializationTestForResourceSet_STATUS, ResourceSet_STATUSGenerator()))
	properties.TestingRun(t, gopter.NewFormatedReporter(true, 240, os.Stdout))
}

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

	// Deserialize back into memory
	var actual ResourceSet_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 ResourceSet_STATUS instances for property testing - lazily instantiated by ResourceSet_STATUSGenerator()
var resourceSet_STATUSGenerator gopter.Gen

// ResourceSet_STATUSGenerator returns a generator of ResourceSet_STATUS instances for property testing.
func ResourceSet_STATUSGenerator() gopter.Gen {
	if resourceSet_STATUSGenerator != nil {
		return resourceSet_STATUSGenerator
	}

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

	return resourceSet_STATUSGenerator
}

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

func Test_Subnet_PrivateLinkService_SubResourceEmbedded_WhenPropertiesConverted_RoundTripsWithoutLoss(t *testing.T) {
	t.Parallel()
	parameters := gopter.DefaultTestParameters()
	parameters.MaxSize = 10
	properties := gopter.NewProperties(parameters)
	properties.Property(
		"Round trip from Subnet_PrivateLinkService_SubResourceEmbedded to Subnet_PrivateLinkService_SubResourceEmbedded via AssignProperties_To_Subnet_PrivateLinkService_SubResourceEmbedded & AssignProperties_From_Subnet_PrivateLinkService_SubResourceEmbedded returns original",
		prop.ForAll(RunPropertyAssignmentTestForSubnet_PrivateLinkService_SubResourceEmbedded, Subnet_PrivateLinkService_SubResourceEmbeddedGenerator()))
	properties.TestingRun(t, gopter.NewFormatedReporter(false, 240, os.Stdout))
}

// RunPropertyAssignmentTestForSubnet_PrivateLinkService_SubResourceEmbedded tests if a specific instance of Subnet_PrivateLinkService_SubResourceEmbedded can be assigned to storage and back losslessly
func RunPropertyAssignmentTestForSubnet_PrivateLinkService_SubResourceEmbedded(subject Subnet_PrivateLinkService_SubResourceEmbedded) 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.Subnet_PrivateLinkService_SubResourceEmbedded
	err := copied.AssignProperties_To_Subnet_PrivateLinkService_SubResourceEmbedded(&other)
	if err != nil {
		return err.Error()
	}

	// Use AssignPropertiesFrom() to convert back to our original type
	var actual Subnet_PrivateLinkService_SubResourceEmbedded
	err = actual.AssignProperties_From_Subnet_PrivateLinkService_SubResourceEmbedded(&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_Subnet_PrivateLinkService_SubResourceEmbedded_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 Subnet_PrivateLinkService_SubResourceEmbedded via JSON returns original",
		prop.ForAll(RunJSONSerializationTestForSubnet_PrivateLinkService_SubResourceEmbedded, Subnet_PrivateLinkService_SubResourceEmbeddedGenerator()))
	properties.TestingRun(t, gopter.NewFormatedReporter(true, 240, os.Stdout))
}

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

	// Deserialize back into memory
	var actual Subnet_PrivateLinkService_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 Subnet_PrivateLinkService_SubResourceEmbedded instances for property testing - lazily instantiated by
// Subnet_PrivateLinkService_SubResourceEmbeddedGenerator()
var subnet_PrivateLinkService_SubResourceEmbeddedGenerator gopter.Gen

// Subnet_PrivateLinkService_SubResourceEmbeddedGenerator returns a generator of Subnet_PrivateLinkService_SubResourceEmbedded instances for property testing.
func Subnet_PrivateLinkService_SubResourceEmbeddedGenerator() gopter.Gen {
	if subnet_PrivateLinkService_SubResourceEmbeddedGenerator != nil {
		return subnet_PrivateLinkService_SubResourceEmbeddedGenerator
	}

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

	return subnet_PrivateLinkService_SubResourceEmbeddedGenerator
}

func Test_Subnet_STATUS_PrivateLinkService_SubResourceEmbedded_WhenPropertiesConverted_RoundTripsWithoutLoss(t *testing.T) {
	t.Parallel()
	parameters := gopter.DefaultTestParameters()
	parameters.MaxSize = 10
	properties := gopter.NewProperties(parameters)
	properties.Property(
		"Round trip from Subnet_STATUS_PrivateLinkService_SubResourceEmbedded to Subnet_STATUS_PrivateLinkService_SubResourceEmbedded via AssignProperties_To_Subnet_STATUS_PrivateLinkService_SubResourceEmbedded & AssignProperties_From_Subnet_STATUS_PrivateLinkService_SubResourceEmbedded returns original",
		prop.ForAll(RunPropertyAssignmentTestForSubnet_STATUS_PrivateLinkService_SubResourceEmbedded, Subnet_STATUS_PrivateLinkService_SubResourceEmbeddedGenerator()))
	properties.TestingRun(t, gopter.NewFormatedReporter(false, 240, os.Stdout))
}

// RunPropertyAssignmentTestForSubnet_STATUS_PrivateLinkService_SubResourceEmbedded tests if a specific instance of Subnet_STATUS_PrivateLinkService_SubResourceEmbedded can be assigned to storage and back losslessly
func RunPropertyAssignmentTestForSubnet_STATUS_PrivateLinkService_SubResourceEmbedded(subject Subnet_STATUS_PrivateLinkService_SubResourceEmbedded) 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.Subnet_STATUS_PrivateLinkService_SubResourceEmbedded
	err := copied.AssignProperties_To_Subnet_STATUS_PrivateLinkService_SubResourceEmbedded(&other)
	if err != nil {
		return err.Error()
	}

	// Use AssignPropertiesFrom() to convert back to our original type
	var actual Subnet_STATUS_PrivateLinkService_SubResourceEmbedded
	err = actual.AssignProperties_From_Subnet_STATUS_PrivateLinkService_SubResourceEmbedded(&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_Subnet_STATUS_PrivateLinkService_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 Subnet_STATUS_PrivateLinkService_SubResourceEmbedded via JSON returns original",
		prop.ForAll(RunJSONSerializationTestForSubnet_STATUS_PrivateLinkService_SubResourceEmbedded, Subnet_STATUS_PrivateLinkService_SubResourceEmbeddedGenerator()))
	properties.TestingRun(t, gopter.NewFormatedReporter(true, 240, os.Stdout))
}

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

	// Deserialize back into memory
	var actual Subnet_STATUS_PrivateLinkService_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 Subnet_STATUS_PrivateLinkService_SubResourceEmbedded instances for property testing - lazily
// instantiated by Subnet_STATUS_PrivateLinkService_SubResourceEmbeddedGenerator()
var subnet_STATUS_PrivateLinkService_SubResourceEmbeddedGenerator gopter.Gen

// Subnet_STATUS_PrivateLinkService_SubResourceEmbeddedGenerator returns a generator of Subnet_STATUS_PrivateLinkService_SubResourceEmbedded instances for property testing.
func Subnet_STATUS_PrivateLinkService_SubResourceEmbeddedGenerator() gopter.Gen {
	if subnet_STATUS_PrivateLinkService_SubResourceEmbeddedGenerator != nil {
		return subnet_STATUS_PrivateLinkService_SubResourceEmbeddedGenerator
	}

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

	return subnet_STATUS_PrivateLinkService_SubResourceEmbeddedGenerator
}

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