From 5e8737e2bbf325c12163c8f96c6e3e9438bdbf30 Mon Sep 17 00:00:00 2001 From: Janez Podhostnik Date: Thu, 16 May 2024 16:34:21 +0200 Subject: [PATCH] add tests --- contracts/DependencyAudit.cdc | 12 +- flow.json | 320 +++++++++--------- lib/go/contracts/internal/assets/assets.go | 23 ++ lib/go/templates/internal/assets/assets.go | 50 +++ tests/dependency_audit_tests.cdc | 220 ++++++++++++ .../admin/set_unstaged_cause_panic.cdc | 8 + .../admin/test_check_dependencies.cdc | 8 + 7 files changed, 473 insertions(+), 168 deletions(-) create mode 100644 tests/dependency_audit_tests.cdc create mode 100644 transactions/dependency-audit/admin/set_unstaged_cause_panic.cdc create mode 100644 transactions/dependency-audit/admin/test_check_dependencies.cdc diff --git a/contracts/DependencyAudit.cdc b/contracts/DependencyAudit.cdc index 619e9ce..651b0d9 100644 --- a/contracts/DependencyAudit.cdc +++ b/contracts/DependencyAudit.cdc @@ -21,12 +21,11 @@ access(all) contract DependencyAudit { // checkDependencies is called from the FlowServiceAccount contract access(self) fun checkDependencies(_ dependenciesAddresses: [Address], _ dependenciesNames: [String], _ authorizers: [Address]) { - var numDependencies = dependenciesAddresses.length - var i = 0 - var unstagedDependenciesAddresses: [Address] = [] var unstagedDependenciesNames: [String] = [] + var numDependencies = dependenciesAddresses.length + var i = 0 while i < numDependencies { let isExcluded = DependencyAudit.excludedAddresses[dependenciesAddresses[i]] ?? false if isExcluded { @@ -89,6 +88,13 @@ access(all) contract DependencyAudit { DependencyAudit.panicOnUnstaged = shouldPanic emit PanicOnUnstagedDependenciesChanged(shouldPanic: shouldPanic) } + + // testCheckDependencies is used for testing purposes + // It will call the `checkDependencies` function with the provided dependencies + // `checkDependencies` is otherwise not callable from the outside + access(all) fun testCheckDependencies(_ dependenciesAddresses: [Address], _ dependenciesNames: [String], _ authorizers: [Address]) { + return DependencyAudit.checkDependencies(dependenciesAddresses, dependenciesNames, authorizers) + } } // The admin resource is saved to the storage so that the admin can be accessed by the service account diff --git a/flow.json b/flow.json index 5e013e9..5c9b016 100644 --- a/flow.json +++ b/flow.json @@ -1,166 +1,156 @@ { - "contracts": { - "A": { - "source": "./contracts/test/A.cdc", - "aliases": { - "emulator": "179b6b1cb6755e31", - "testing": "0000000000000009" - } - }, - "B": { - "source": "./contracts/test/B.cdc", - "aliases": { - "emulator": "f3fcd2c1a78f5eee", - "testing": "0000000000000010" - } - }, - "C": { - "source": "./contracts/test/C.cdc", - "aliases": { - "emulator": "f3fcd2c1a78f5eee", - "testing": "0000000000000010" - } - }, - "Foo": { - "source": "./contracts/test/Foo.cdc", - "aliases": { - "emulator": "01cf0e2f2f715450", - "testing": "0000000000000008" - } - }, - "FungibleToken": { - "source": "./contracts/standards/FungibleToken.cdc", - "aliases": { - "emulator": "ee82856bf20e2aa6", - "mainnet": "f233dcee88fe0abe", - "testnet": "9a0766d93b6608b7" - } - }, - "MetadataViews": { - "source": "./contracts/standards/MetadataViews.cdc", - "aliases": { - "emulator": "f8d6e0586b0a20c7", - "mainnet": "1d7e57aa55817448", - "testnet": "631e88ae7f1d7c20" - } - }, - "MigrationContractStaging": { - "source": "./contracts/MigrationContractStaging.cdc", - "aliases": { - "crescendo": "27b2302520211b67", - "emulator": "f8d6e0586b0a20c7", - "mainnet": "56100d46aa9b0212", - "testing": "0000000000000007", - "testnet": "2ceae959ed1a7e7a" - } - }, - "NonFungibleToken": { - "source": "./contracts/standards/NonFungibleToken.cdc", - "aliases": { - "emulator": "f8d6e0586b0a20c7", - "mainnet": "1d7e57aa55817448", - "testnet": "631e88ae7f1d7c20" - } - }, - "StagedContractUpdates": { - "source": "./contracts/staged-contract-updates/StagedContractUpdates.cdc", - "aliases": { - "emulator": "f8d6e0586b0a20c7", - "testing": "0000000000000007" - } - } - }, - "networks": { - "crescendo": "access.crescendo.nodes.onflow.org: 9000", - "emulator": "127.0.0.1:3569", - "mainnet": "access.mainnet.nodes.onflow.org:9000", - "sandboxnet": "access.sandboxnet.nodes.onflow.org:9000", - "testing": "127.0.0.1:3569", - "testnet": "access.devnet.nodes.onflow.org:9000" - }, - "accounts": { - "a-account": { - "address": "179b6b1cb6755e31", - "key": "1bbaf3239cfd9e8e35f85723f6c70f2ac5c8f50856c4667021cf9ed72eabd9f8" - }, - "abc-updater": { - "address": "e03daebed8ca0615", - "key": "caa4da634fee3ad45ce67ef8a6813987888d88f4b4e6e70b8d84685845db7f25" - }, - "bc-account": { - "address": "f3fcd2c1a78f5eee", - "key": "c06a4b0fce3bc3088a2a2e3b11a9ea5d13e251661cefa3f26af1180ad317d3dc" - }, - "emulator-account": { - "address": "f8d6e0586b0a20c7", - "key": "a08c990a1f7adb14c290d05df0f397d2de2f4d0cb18cdffed592f611f95f5d08" - }, - "emulator-ft": { - "address": "ee82856bf20e2aa6", - "key": "686779d775e5fcbf8d2f4a85cb4c53525d02b7ef53230d180fc16f35d9b7d025" - }, - "foo": { - "address": "01cf0e2f2f715450", - "key": "e9b7b36e9d16f47501db73e84c68e441609475ee482ee808411b2fe0bd2329da" - }, - "migration-contract-staging-crescendo": { - "address": "27b2302520211b67", - "key": { - "type": "google-kms", - "hashAlgorithm": "SHA2_256", - "resourceID": "projects/dl-flow-admin/locations/global/keyRings/migration-contract-staging-testnet/cryptoKeys/evm-storage-testnet-key/cryptoKeyVersions/1" - } - }, - "migration-contract-staging-mainnet": { - "address": "56100d46aa9b0212", - "key": { - "type": "google-kms", - "hashAlgorithm": "SHA2_256", - "resourceID": "projects/dl-flow-admin/locations/global/keyRings/migration-contract-staging-mainnet/cryptoKeys/evm-storage-mainnet-key/cryptoKeyVersions/1" - } - }, - "migration-contract-staging-testnet": { - "address": "2ceae959ed1a7e7a", - "key": { - "type": "google-kms", - "hashAlgorithm": "SHA2_256", - "resourceID": "projects/dl-flow-admin/locations/global/keyRings/migration-contract-staging-testnet/cryptoKeys/evm-storage-testnet-key/cryptoKeyVersions/1" - } - } - }, - "deployments": { - "crescendo": { - "migration-contract-staging-crescendo": [ - "MigrationContractStaging" - ] - }, - "emulator": { - "a-account": [ - "A" - ], - "bc-account": [ - "B", - "C" - ], - "emulator-account": [ - "MigrationContractStaging" - ], - "emulator-ft": [ - "FungibleToken" - ], - "foo": [ - "Foo" - ] - }, - "mainnet": { - "migration-contract-staging-mainnet": [ - "MigrationContractStaging" - ] - }, - "testnet": { - "migration-contract-staging-testnet": [ - "MigrationContractStaging" - ] - } - } -} \ No newline at end of file + "contracts": { + "A": { + "source": "./contracts/test/A.cdc", + "aliases": { + "emulator": "179b6b1cb6755e31", + "testing": "0000000000000009" + } + }, + "B": { + "source": "./contracts/test/B.cdc", + "aliases": { + "emulator": "f3fcd2c1a78f5eee", + "testing": "0000000000000010" + } + }, + "C": { + "source": "./contracts/test/C.cdc", + "aliases": { + "emulator": "f3fcd2c1a78f5eee", + "testing": "0000000000000010" + } + }, + "Foo": { + "source": "./contracts/test/Foo.cdc", + "aliases": { + "emulator": "01cf0e2f2f715450", + "testing": "0000000000000008" + } + }, + "FungibleToken": { + "source": "./contracts/standards/FungibleToken.cdc", + "aliases": { + "emulator": "ee82856bf20e2aa6", + "mainnet": "f233dcee88fe0abe", + "testnet": "9a0766d93b6608b7" + } + }, + "MetadataViews": { + "source": "./contracts/standards/MetadataViews.cdc", + "aliases": { + "emulator": "f8d6e0586b0a20c7", + "mainnet": "1d7e57aa55817448", + "testnet": "631e88ae7f1d7c20" + } + }, + "MigrationContractStaging": { + "source": "./contracts/MigrationContractStaging.cdc", + "aliases": { + "crescendo": "27b2302520211b67", + "emulator": "f8d6e0586b0a20c7", + "mainnet": "56100d46aa9b0212", + "testing": "0000000000000007", + "testnet": "2ceae959ed1a7e7a" + } + }, + "NonFungibleToken": { + "source": "./contracts/standards/NonFungibleToken.cdc", + "aliases": { + "emulator": "f8d6e0586b0a20c7", + "mainnet": "1d7e57aa55817448", + "testnet": "631e88ae7f1d7c20" + } + }, + "StagedContractUpdates": { + "source": "./contracts/staged-contract-updates/StagedContractUpdates.cdc", + "aliases": { + "emulator": "f8d6e0586b0a20c7", + "testing": "0000000000000007" + } + }, + "DependencyAudit": { + "source": "./contracts/DependencyAudit.cdc", + "aliases": { + "emulator": "f8d6e0586b0a20c7", + "testing": "0000000000000007" + } + } + }, + "networks": { + "crescendo": "access.crescendo.nodes.onflow.org: 9000", + "emulator": "127.0.0.1:3569", + "mainnet": "access.mainnet.nodes.onflow.org:9000", + "sandboxnet": "access.sandboxnet.nodes.onflow.org:9000", + "testing": "127.0.0.1:3569", + "testnet": "access.devnet.nodes.onflow.org:9000" + }, + "accounts": { + "a-account": { + "address": "179b6b1cb6755e31", + "key": "1bbaf3239cfd9e8e35f85723f6c70f2ac5c8f50856c4667021cf9ed72eabd9f8" + }, + "abc-updater": { + "address": "e03daebed8ca0615", + "key": "caa4da634fee3ad45ce67ef8a6813987888d88f4b4e6e70b8d84685845db7f25" + }, + "bc-account": { + "address": "f3fcd2c1a78f5eee", + "key": "c06a4b0fce3bc3088a2a2e3b11a9ea5d13e251661cefa3f26af1180ad317d3dc" + }, + "emulator-account": { + "address": "f8d6e0586b0a20c7", + "key": "a08c990a1f7adb14c290d05df0f397d2de2f4d0cb18cdffed592f611f95f5d08" + }, + "emulator-ft": { + "address": "ee82856bf20e2aa6", + "key": "686779d775e5fcbf8d2f4a85cb4c53525d02b7ef53230d180fc16f35d9b7d025" + }, + "foo": { + "address": "01cf0e2f2f715450", + "key": "e9b7b36e9d16f47501db73e84c68e441609475ee482ee808411b2fe0bd2329da" + }, + "migration-contract-staging-crescendo": { + "address": "27b2302520211b67", + "key": { + "type": "google-kms", + "hashAlgorithm": "SHA2_256", + "resourceID": "projects/dl-flow-admin/locations/global/keyRings/migration-contract-staging-testnet/cryptoKeys/evm-storage-testnet-key/cryptoKeyVersions/1" + } + }, + "migration-contract-staging-mainnet": { + "address": "56100d46aa9b0212", + "key": { + "type": "google-kms", + "hashAlgorithm": "SHA2_256", + "resourceID": "projects/dl-flow-admin/locations/global/keyRings/migration-contract-staging-mainnet/cryptoKeys/evm-storage-mainnet-key/cryptoKeyVersions/1" + } + }, + "migration-contract-staging-testnet": { + "address": "2ceae959ed1a7e7a", + "key": { + "type": "google-kms", + "hashAlgorithm": "SHA2_256", + "resourceID": "projects/dl-flow-admin/locations/global/keyRings/migration-contract-staging-testnet/cryptoKeys/evm-storage-testnet-key/cryptoKeyVersions/1" + } + } + }, + "deployments": { + "crescendo": { + "migration-contract-staging-crescendo": ["MigrationContractStaging"] + }, + "emulator": { + "a-account": ["A"], + "bc-account": ["B", "C"], + "emulator-account": ["MigrationContractStaging", "DependencyAudit"], + "emulator-ft": ["FungibleToken"], + "foo": ["Foo"] + }, + "mainnet": { + "migration-contract-staging-mainnet": ["MigrationContractStaging"] + }, + "testnet": { + "migration-contract-staging-testnet": ["MigrationContractStaging"] + } + } +} diff --git a/lib/go/contracts/internal/assets/assets.go b/lib/go/contracts/internal/assets/assets.go index b7453af..f9becc7 100644 --- a/lib/go/contracts/internal/assets/assets.go +++ b/lib/go/contracts/internal/assets/assets.go @@ -1,5 +1,6 @@ // Code generated by go-bindata. DO NOT EDIT. // sources: +// DependencyAudit.cdc (5.701kB) // MigrationContractStaging.cdc (19.438kB) package assets @@ -69,6 +70,26 @@ func (fi bindataFileInfo) Sys() interface{} { return nil } +var _dependencyauditCdc = "\x1f\x8b\x08\x00\x00\x00\x00\x00\x00\xff\xbc\x58\xdd\x6f\xdb\x36\x10\x7f\xcf\x5f\x71\xf3\x93\x85\xb9\x4a\x3b\x60\x28\x6a\xd4\x2b\xb2\xae\x05\xf6\xd0\xad\x40\xb6\xbd\x18\x46\xcd\x48\x27\x9b\x89\x44\x1a\x24\x65\xd7\x0b\xf2\xbf\x0f\x47\xea\x9b\x94\x9c\x3e\xac\x02\x5a\x44\xd6\x7d\xfe\xee\x78\x1f\xe4\xc5\x41\x2a\x03\xb3\x4f\x7c\xa7\x98\xe1\x52\xbc\x97\xc2\x28\x96\x98\x5b\xc3\x76\x5c\xec\x66\x57\x57\xd7\xd7\xf0\xd7\x9e\x6b\x48\xaa\x2f\xc0\x35\xfd\x83\x52\x63\x0a\x77\x67\x30\x7b\x84\x8f\xff\x7c\x82\x84\xe5\x39\x17\x3b\xfb\xbe\x4d\xf6\x98\x3c\xfc\x86\x07\x14\x29\x8a\x84\xa3\xde\x42\x56\x8a\x84\x34\x40\xa6\x64\x01\xac\x7d\x97\x99\xe5\xd1\xac\x40\x10\xf4\x1f\x13\x29\x68\x2e\x76\xcc\x94\x0a\x81\x0b\xa7\x22\x97\xa7\x5b\x54\x47\x9e\xe0\x4d\x92\xc8\x52\x98\xc6\xa2\x05\xd9\xc8\x8c\x25\x43\x91\x92\x40\x3c\xa2\x3a\x83\x51\x4c\x68\x66\xb5\xc4\xce\x0f\x84\x6d\xda\xb1\xea\x26\x4d\x15\x6a\x4d\xe6\x91\xd2\xde\xb7\x3f\x58\x41\xbf\x9f\x78\x9e\xc3\x1d\x02\xcb\x73\xab\xa0\x4b\x02\x02\x31\x4d\x31\x05\x23\x41\x95\x64\x27\x59\xd1\x57\xda\xe8\x9d\x82\xc4\x2a\xb1\x04\xc0\x33\x60\xe2\x5c\x83\xd2\xd3\xc6\x14\x82\x90\x06\xb4\x61\x3b\x4c\x6b\x60\xc6\x42\xd7\xc0\x63\x5d\xff\xfd\xb9\x62\x17\x96\xa0\x6f\x19\x16\xdc\x00\x13\x84\xaa\x30\x70\xe2\x66\x6f\x89\x4a\x51\x59\xd2\x15\xb7\x00\xa9\xe0\xc0\x04\x4f\xc8\x95\xad\xfd\xeb\x4f\xf1\x77\x45\xba\xa5\xcc\xd1\x68\x08\x31\xa3\x4a\x8c\xaf\x58\x92\xa0\xd6\x73\x96\xe7\x51\x9b\x62\x0d\x4c\xe7\x9b\x32\xe5\x06\x1e\xaf\xae\x00\x00\xba\xb4\x39\x1a\xb8\x49\x0b\x2e\xb8\x36\x8a\x19\xa9\x6e\x8d\x54\x6c\x87\x9f\x99\xd9\x2f\xa1\xf3\xe2\x58\xab\x28\xe8\xb3\x36\x58\x00\xab\xe3\x0e\x7b\x76\xc4\x46\xaf\x76\x11\xb4\x3e\x13\x22\x77\xe8\x40\xd1\x70\xe4\xcc\xba\x5c\xd4\x60\xb7\xb6\x6a\x09\x27\x04\xfc\x9a\xe4\x65\x8a\x44\x54\xb8\x0c\xef\xe1\x7c\xa6\xe8\x3e\x24\xba\xeb\x86\xc6\x3c\x8b\xe0\xc8\x54\xcd\x9c\x36\xe9\xb8\x84\xc7\xea\xef\x25\xfc\x2a\x65\xfe\xe4\xfb\x4f\x7c\x03\x70\x1d\xad\x4f\xea\xc2\x56\x53\x75\x53\x70\x1e\x3c\x0c\x4b\x58\x57\x7f\x6f\x16\xe0\x1d\x89\x25\xac\x6f\x8d\xe2\x62\xb7\x89\xc6\x54\x7d\xee\xdb\xd5\xd5\xf8\x7e\xcf\xc4\x0e\xd3\xb9\xde\xcb\x32\x4f\x2d\xa1\x33\x3b\x6a\xe2\xe4\x1d\x14\xca\x19\xaa\x2e\x98\xb6\xc8\x4e\x94\x03\x1f\xe3\xac\x14\xbe\xd4\xf9\x17\xb8\xec\xfd\x97\x29\xff\xe9\x33\x2b\xcd\x5e\x2a\xfe\x2f\xaa\x2e\x63\x04\x8f\xd6\x0a\x7a\x28\x50\x65\x00\x89\x90\x42\x58\xc1\x7a\x73\x91\x73\x60\x86\x63\xea\x71\x89\xb2\xe8\x01\xb8\x0a\xbb\x1a\xe7\x28\x76\x66\xdf\x63\xe5\xb0\x82\x97\xcd\x2f\xa7\x3d\xcf\x11\x38\xbc\xf5\x44\xb6\x0e\xd2\x43\xa7\x91\xeb\x0f\x55\x1e\xc3\x6a\x78\x82\x63\x2f\xc5\xd7\x41\x8b\xd6\x7c\xb3\x81\x77\xef\x20\x63\xb9\xc6\x9e\x06\x9e\x75\x15\xf4\xb5\xdb\xef\xb0\x02\x0e\x3f\xc2\x2b\xef\x0b\xe5\x05\x17\x65\x5f\xdc\xd3\x95\x67\x7f\x55\xcc\x56\xa3\x15\x35\xe6\xfa\xd6\xd2\xcc\x59\x7d\x38\xc7\x9c\x58\xd8\x4e\xb6\xf4\xb3\x67\xcd\x37\xd1\xd0\xaf\x1f\x2a\xcd\xbe\x53\x93\x79\x13\xb3\x03\xfd\x1a\x3e\xc3\x9e\x9e\x31\x71\xd6\xaa\x90\xa8\xb0\xb9\x03\xdc\x7c\xd4\x3b\x04\x3c\xbb\xe0\x80\x4b\x3f\xf8\x05\x5e\x0e\x7c\xe7\x99\x97\x40\x83\x5a\x17\x00\xcb\x75\xb9\x4b\x1d\xc7\xf5\xb7\x4e\x93\x76\xe5\xbe\xe9\x58\x66\x8f\x0a\x6d\x4f\xa4\x7e\x19\x6c\x71\x21\xcd\x24\xd4\xc9\x28\x50\x6b\xb6\x43\x27\x96\x8b\xa6\x2d\x3c\x53\xd6\xd8\xa1\x77\x87\x1d\x56\x30\x9b\x05\x79\x44\x59\x84\xea\x2d\xac\x9e\x15\x83\xa0\xc8\xfb\x5e\x29\xa8\x1f\x57\x12\xee\x5d\x49\x08\xaa\xf4\x43\x53\xc5\xf4\x3e\x10\xea\xee\x33\xe9\xf7\xf8\xc7\x38\x91\x22\x61\x66\x3e\x5b\xc0\xcc\x4f\x7a\xb0\x49\xf9\x7f\xa8\xbb\x89\x67\x51\xfd\x32\x09\xf2\xfa\x7e\x13\x1b\xe9\xb8\xe7\x51\xc3\x33\xbb\xc0\xef\x4e\xe0\x7d\xdd\x67\x87\x0f\x85\xe7\x3e\x58\xf1\x9e\x7c\x86\x2a\x45\x3b\x79\xaf\x5d\x86\x66\x8c\xe7\x6e\xa4\x63\x4d\xea\xda\x29\x28\x97\xf2\x41\x43\xce\x1f\xe8\x9d\xeb\x25\x6c\x51\x29\xa9\x96\x2e\xcd\x97\xf0\x51\x96\x22\x0d\x27\xf5\x12\x6e\xe2\x97\x5f\x7f\x4a\x90\xe1\x9b\x9f\xdf\x60\xfa\x8a\xbd\xc6\xd7\x2c\x1e\xab\xab\x8b\x30\xf9\xa0\x02\x6c\x3d\x9f\xac\x21\xf3\xd9\xa4\x21\xb3\x29\x80\x5d\x44\xa2\x41\x85\x03\xcc\x35\x06\xb2\xd4\x4e\xc1\xdf\x32\x45\x4d\xe6\x44\x70\xb2\x1a\xcd\x82\x61\x11\xee\xff\xf5\xd4\x9b\x71\x7b\x53\x31\x28\xd4\x52\x25\x08\x09\x13\x34\xcf\xda\xad\xcd\x48\x9a\x80\xc1\x7e\x2d\xe4\x11\x3b\xf3\x70\x33\x60\x79\x0d\x1b\x52\x6e\xf3\x86\xa9\x73\xa5\xcd\x9b\xfe\x48\x57\x49\xca\xfa\x26\xb4\x50\xd2\x9e\x96\xa6\x1f\x3c\xd1\x64\x0d\x29\x6d\xed\xa0\x6a\xfd\x1c\x2b\x86\x26\xd0\xa8\x17\x52\x31\x67\x81\x71\x2b\x1a\x44\x39\x93\xaa\x36\x81\xb6\xab\xd6\x1a\x3f\x19\x2e\xcf\x37\xac\x9d\xe9\xa8\xef\x8c\x06\xb0\x0b\x8e\x0b\x87\x8f\x4f\x15\xa6\x3e\x44\xcf\x0f\x55\x08\xa4\x11\x55\xdf\x1d\xa7\xd8\x19\x32\x7f\xc0\xf3\xb2\x96\x34\x9e\xed\x5d\xb0\x34\x9a\x89\x45\x83\x3e\x6b\x77\x19\xe1\x4d\x04\x47\xa6\x38\xbb\xcb\xb1\xce\xb2\x23\xcb\x4b\xa4\xdd\x78\xdb\x59\x4b\xb6\xa3\xd0\x4d\x2b\x0e\xac\x36\x03\x5c\x2e\x8d\x36\x2b\xe8\x88\xe8\x71\xda\x12\xf4\xad\xdb\x55\xe7\x25\x1a\x81\xd2\xa0\x36\xef\x43\x6b\x97\x2d\x17\x14\x6e\xa2\xa0\xc6\x78\x28\xd5\x41\xea\xce\xdc\x42\x53\x57\xb5\x32\x27\xf5\x1d\xc9\x85\xbb\x8e\xea\xfa\xe0\xa0\xe4\x91\xa7\x63\xf3\xd0\xf5\x75\x50\x0c\xd7\x20\x69\x44\x3b\x71\xed\x6e\x2d\x48\xa9\x8d\x65\x73\x1c\x64\x69\x34\x4f\x71\x34\x7c\x41\x67\xbf\xd7\x36\x48\x8f\x42\x53\x2a\xe1\xa5\x81\xbf\xa1\x06\x2d\x0a\x34\x8e\x45\x57\x71\x34\xd9\x1c\x18\x55\xe6\xb6\x50\xd3\x6c\xcc\x8e\xae\x25\xd8\x4b\x38\x77\x6f\x02\x5a\x56\x97\x59\x0d\x4b\xd5\x3f\x1c\x98\xed\xcd\x9f\x76\x3b\x38\xfd\x4e\x4b\x78\x57\xd5\xd6\x3b\xeb\xed\x6d\x5a\xbf\x92\x35\x29\x51\x5d\xcf\x54\x9b\xbc\xbd\x92\x89\xad\x48\x2e\xb8\x99\x07\xae\x49\x82\x18\xd3\xd2\xef\x17\x1a\x58\xc1\xe3\x53\x9f\xc6\x3f\x78\x6e\xef\xec\x53\x8d\xdd\x32\xc1\x0a\xae\x2b\xbc\xae\xb3\x5c\x9e\x06\xf1\xb4\x6c\xad\xa8\x41\xcd\xf4\xcd\xeb\xe7\x48\xd8\x87\xd1\xa6\xd2\x39\xce\xb4\xca\xba\x90\xbd\x7d\x01\x89\x42\x66\x06\xfd\x78\x1e\xf5\xfd\xab\x42\x17\x53\x22\xcc\xdf\xbe\xb0\xbc\x0b\x30\x72\x39\xed\x7e\x54\x65\xd7\xd3\xd5\x7f\x01\x00\x00\xff\xff\x1f\x18\x00\x75\x45\x16\x00\x00" + +func dependencyauditCdcBytes() ([]byte, error) { + return bindataRead( + _dependencyauditCdc, + "DependencyAudit.cdc", + ) +} + +func dependencyauditCdc() (*asset, error) { + bytes, err := dependencyauditCdcBytes() + if err != nil { + return nil, err + } + + info := bindataFileInfo{name: "DependencyAudit.cdc", size: 0, mode: os.FileMode(0), modTime: time.Unix(0, 0)} + a := &asset{bytes: bytes, info: info, digest: [32]uint8{0xf5, 0xdf, 0x4b, 0x1c, 0xa5, 0xf6, 0xdf, 0x39, 0xb7, 0x3d, 0xab, 0x2f, 0xbe, 0x63, 0xbe, 0x5c, 0x16, 0xb, 0x1c, 0x46, 0x74, 0xb2, 0x4a, 0x35, 0x1d, 0x8, 0xdf, 0xe2, 0xd7, 0xf9, 0xa7, 0xb4}} + return a, nil +} + var _migrationcontractstagingCdc = "\x1f\x8b\x08\x00\x00\x00\x00\x00\x00\xff\xbc\x3c\xcb\x72\x5b\xb9\xb1\x7b\x7f\x45\x8b\x0b\x9b\xbc\x45\x51\x93\xa9\x5b\x77\xa1\x32\xe3\x51\x64\xcf\x1d\x2f\xec\x71\x59\x72\xb2\x70\xb9\x26\xd0\x39\x4d\x12\xe5\x43\x80\x05\xe0\x88\xd6\x75\xbc\xcf\x77\xde\x2f\x49\xe1\xfd\x38\x07\x24\xad\x99\x1a\x56\x12\xdb\x24\x80\x7e\xa0\xbb\xd1\xcf\x5c\x5c\x5c\xc0\xed\x86\x4a\x68\x38\x53\x82\x34\x0a\xa8\x04\xca\x14\xb2\x16\x5b\x58\x71\x01\xbd\x44\xa0\x0c\xd4\x06\xe1\x9a\xb4\xc8\x1a\x84\xbf\x2c\x7e\x88\xeb\xb7\x74\x2d\x88\xa2\x9c\x01\x69\x04\x97\xd2\xac\xfc\xb9\xe3\x7b\x60\xa8\xf6\x5c\x7c\x5e\x3c\xb9\xb8\xb8\xd0\xff\x85\xd7\x0c\x76\x02\x77\xc4\xad\xd7\xa7\x2b\x0d\x7b\x4b\x3b\x94\x8a\x33\x9c\xc3\x03\xef\x45\x3c\x7b\x4f\xbb\x0e\xde\xbe\x7a\xf5\x12\x14\x87\x3b\x84\x7e\xd7\x12\x85\xed\x19\xfc\xaa\xd1\x78\xe0\xfd\xb3\xfb\xf0\xa5\xdf\xda\xa2\x3e\xd8\xc0\x4b\xf0\x35\x27\xc3\x9b\x0f\x37\xb7\x20\x15\x59\x63\x01\xc8\x6c\x33\x54\xa6\xac\x90\x1c\xd4\x86\x28\x43\x91\x85\x02\x0d\x61\x1a\x11\xfc\x82\x4d\xaf\x81\x12\x09\x04\x76\x44\x28\xe0\x2b\xbd\xce\xc0\x75\x84\x9f\xef\x69\x8b\x1a\x9c\xc2\xc8\xa5\xc8\x8d\x5b\x3e\x8a\x8a\x05\x74\x69\x96\xfc\x65\x01\x8d\x40\xbd\x9f\xc0\x2f\x5c\x2a\x78\x0a\x92\xdc\x1b\x4c\xb3\x4d\xe7\x1b\x2e\x15\x65\x6b\x20\x4d\xc3\x7b\xa6\xcc\xe6\x1f\x17\xd0\x90\xae\xb3\x40\xae\xdd\xca\xe9\x0c\x76\x44\x4a\xb3\x16\x04\xae\x50\x18\x0e\x29\x6e\xf8\xa3\x61\xcc\x0d\xb9\x01\x1d\x46\xb6\x38\x07\xc2\xda\x84\x0b\x6d\xe0\xac\xe6\x5b\x24\xc8\x30\xcf\x32\xa8\xe5\xcc\xa0\x49\x40\xc3\xea\x10\x94\x20\x4c\x92\x46\xb3\xe0\x0c\x7e\xe6\x02\xb6\x5c\xd8\xfd\x06\x16\x7e\x51\x73\x90\x88\xb0\x51\x6a\x27\x2f\x2f\x2e\xd6\x54\x6d\xfa\xbb\x45\xc3\xb7\x17\x9c\xad\x3a\xbe\xbf\x08\xc4\x5a\x24\xcc\x15\x3f\x21\x4d\x83\x52\x4e\x49\xd7\xcd\x22\xce\x6f\x3c\xb3\x3d\xd5\x37\x8a\xac\x35\xc9\x5f\x9f\x3c\x01\x00\xb8\xb8\x80\x77\x44\x6d\xf4\x06\xa9\x08\x53\xd2\x7d\x6b\xfe\x70\x27\x4a\xec\x56\x33\xe8\x50\x41\x8b\x1d\xdd\x52\x85\xe2\x12\x6e\x94\xa0\x6c\x3d\xbe\xac\x21\x3b\xd9\x77\xa8\x0f\x7e\x27\x70\x45\xbf\x8c\x2d\x37\x78\xea\xd5\x9a\xd3\x37\x8a\x0b\xb2\x36\x3b\xf4\xda\xf0\x8f\xd1\x0d\x57\xed\x96\xb2\x83\x3b\xf4\x15\xbc\x21\xbb\x44\x7e\x49\xdb\x0a\x94\x12\xa5\xbe\x5f\xc2\x80\x08\x41\x1e\xb4\xa0\x1a\x91\x68\xf3\x4b\x96\xe3\x64\xd9\xa5\x9e\x91\xf2\x12\xbe\x5e\xd9\x53\x2f\xe1\xa3\xa5\xef\xd3\xb7\x00\xfe\x76\x83\x70\xd7\xf1\xe6\x33\x6c\x90\xae\x37\x0a\x88\x82\xfd\x86\x36\x1b\x27\x38\x56\x3c\x18\xd7\xff\xe9\x38\x5b\xa3\xd0\xb2\x62\x41\x2c\xe0\xf5\x0a\x18\xed\xe6\xd9\xda\xf0\x33\x50\xd6\xe2\x8a\x32\xaa\xb0\x7b\x80\x9e\x29\xda\x05\xb0\x46\x60\x7b\xc5\x57\x2b\xb8\x27\x5d\x8f\xda\x86\x49\x54\x8b\x21\x45\xf7\x44\x98\xf3\x28\x5b\x5f\x9b\x0d\x97\xf0\xe1\x35\x53\xff\xf3\xdf\x2f\xc2\x61\xef\x51\xf6\x9d\x92\x4e\x9f\xa1\x23\x52\x01\x6e\xfb\xce\xc8\xfd\xd0\xea\xcd\xa1\xe1\xdb\x2d\x55\xfa\xd7\xbb\x07\xb3\x85\xe8\xab\x02\xb2\x52\x28\x80\xaf\x56\xcd\x86\x50\x36\xb2\x73\x70\xcd\x1a\x39\x0d\xee\x95\x83\x16\xc4\xd8\xa2\x74\x09\x95\x1f\x5e\x3c\x09\xc8\xbf\xba\x47\xa6\xd1\xb5\xf8\xec\x37\xa8\x35\xd0\x83\x7e\x26\x9d\x9d\x93\x8e\xa7\x73\x10\xb8\xeb\x48\x83\x2d\x68\x43\xcf\xec\xb7\xe1\xb0\x7f\x5a\x75\xfd\x27\xfc\xff\xbf\xff\x0d\x5f\x27\xe6\xd7\xc9\x1c\x26\x6e\x93\xfe\xab\xdb\x33\xf9\x06\x48\x9a\x0d\xb4\xc8\xb8\xb1\x43\x86\x0d\x66\x37\xdc\xa1\xf9\x82\x7c\x46\x06\xdc\xbe\x23\x85\xf8\x05\x80\x6f\x7f\xbd\x7d\x75\x09\x2f\x39\x4a\x60\x5c\xc1\xba\x27\x82\x30\x85\x18\xad\x70\x61\xb0\xa5\xbe\x6f\x1a\xcc\xd1\x80\xa3\x68\xd8\xe1\xb4\xff\x46\x11\xd5\xcb\x0f\xd6\x82\x4d\xcd\x5a\xfd\x71\x7a\xfb\xe1\xc3\xeb\x97\x5e\x18\xe6\xe1\x47\xe2\x65\xdd\x09\x7d\xfc\x45\x23\xe0\x35\x3c\xfd\xd6\xe2\x37\xfc\xc5\x72\x23\xb3\x09\xb3\x78\x6d\xe9\x85\x1d\x10\x36\x09\x1b\x6d\xfe\xef\x10\xb5\x40\x6d\x77\x1d\x2a\x7d\x8b\xfb\x0d\x0a\x84\x15\xa1\x5d\xa2\xa9\x40\x04\x1a\xc5\xf6\x72\x49\x45\x80\x17\x1f\xfb\x16\x99\xa2\x2b\x8a\x02\xce\xe1\x6a\x71\xf5\xf2\xe5\xfb\x57\x37\x37\x8b\xb7\x57\x6f\x5e\xb9\x53\xdd\x57\x9a\xd7\xfa\x02\xf4\x43\xe3\xb9\x02\x7b\xaa\x36\xbc\x57\xf0\xc3\x97\x0a\xe7\x2b\x02\x7b\xed\x35\x26\xde\x82\x64\x64\x27\x37\x5c\xdd\xd2\x2d\x4a\x45\xb6\xbb\x4b\xf8\xf0\x33\xfd\x92\xde\x45\xd0\xb3\x03\x6b\x0a\x1e\x44\x1b\x75\x88\xe1\x5e\x24\x83\x51\x88\x56\xc4\xbd\x77\x87\x05\xcb\x6e\xf2\x82\xc5\xbb\x36\x18\x95\x39\x30\xdc\x87\x7f\xcd\x9e\x38\x45\xfd\xaf\x91\x4f\x20\xe1\x5d\x7f\xd7\xd1\x06\xde\xa0\xda\xf0\xd6\x1a\x65\x18\xdb\x70\xe1\x0f\x83\xf3\xf3\x73\x8f\x8a\xdf\x66\xbe\x0b\x4b\xb4\x27\x01\xe7\x70\xed\x5d\x09\x7b\x89\xac\x75\xce\x84\x3a\xea\x4f\x68\x3b\x5e\x7b\x54\x17\xc5\x53\xe6\x41\x06\xd0\x16\xac\xf4\x2e\x8c\x44\x71\x6f\x8e\x96\x41\xfa\x9a\xd4\x1f\x4c\x94\xdc\x41\x5f\xc0\xfb\xd4\x51\x31\x3e\x9a\x40\xc9\x7b\xd1\x60\x94\x60\x23\x9f\x51\xc2\x49\xd7\x19\x28\x4e\x54\x25\xd7\x74\x6e\x7b\xa9\xcc\x93\x42\xee\xcd\x8b\x12\xe8\x93\x16\x7f\xb8\xc3\x95\x76\x4b\xac\xcd\xea\x25\xb6\x1a\xa0\xf5\xd2\x48\xe9\xa2\x2d\x32\x4a\x53\xe9\x58\xf5\xcc\xf9\x6d\x9a\xe2\xe9\xec\x12\x7e\x32\xa4\x7f\x0d\x97\x2c\x50\xf5\x82\xc1\xf3\x73\xef\xdf\xd9\x85\xe6\xf7\x6f\xf1\xd6\x7e\xd4\xb7\x36\xe6\xc3\x69\xcd\x8b\xfa\x18\xfd\x38\x7d\xa9\xd9\xab\x9e\x7f\x63\xac\xa6\x76\xf4\xf6\x54\x6e\x02\x69\x83\x1b\xd3\x37\x6b\xf9\x59\x6c\xf5\x37\xb4\xa6\xf7\xc8\x4a\x40\x6a\x60\x20\xcc\x93\x9e\x9d\x42\x25\x90\x4e\x20\x69\x1f\xfc\x13\x94\x3f\xe2\x1a\x88\x71\xfa\xef\x30\xbc\x4d\x8b\xe2\x7d\xd8\x92\xcf\xe6\x76\x9c\x97\xe0\xa9\x68\xed\x6e\x81\x12\x95\x7b\x17\xac\x58\x49\x63\xf7\x1d\xee\x44\x05\x64\x0e\xdf\x5f\xce\x71\x4d\xd5\x25\x3c\xb5\xfe\xb1\x26\x37\x18\xf8\xec\x21\x98\x25\x57\xbc\x13\x98\xfc\xcb\xd8\x38\xec\x56\x0b\x2a\x9d\xde\xbc\x43\x41\x79\x7b\xd5\x28\x7a\x8f\x5a\x44\x26\x5e\x85\x77\xe6\x07\xd8\x10\x09\x26\x0a\x9b\x84\x43\xbe\x85\xbf\x15\x0e\x27\x2c\xed\xe1\x2d\x0a\x7a\x8f\xd7\xf6\x87\x44\x27\xa7\x9e\xe6\xe0\xbb\x69\x82\x16\xee\x9a\xa6\xb3\x79\x60\xca\x5b\x43\x9b\xa6\x70\x16\x80\xd1\x95\x3d\xbd\x70\x05\x3f\xe6\x67\x7c\x82\xe5\x52\xfb\x6f\x05\xd1\x17\x17\xf0\x33\x15\x52\x81\xa2\x5b\x84\x3d\x3e\x13\xa8\xfd\x7c\x4d\x68\x13\x9e\xaa\x95\xe0\x5b\xab\xd7\x5e\x5f\xcf\x81\x32\x89\x42\x39\x87\xca\x7e\x39\x90\xee\x21\x7b\x0b\x1c\x17\xf6\x94\xe9\x67\x7c\x18\xd2\xfc\x51\x1f\xf1\x69\x56\xa2\x1b\xcc\x24\xc3\x3d\x38\x5e\x5a\x29\xd3\xa6\x21\xf3\x5f\xda\x1c\x83\xe4\x56\xb4\x6a\x1b\x84\xac\x7e\xbb\x63\x9c\x1c\x6d\x12\x31\xb2\xf1\x95\x15\x22\xfd\xbf\xb3\x21\x4d\xde\x0c\x6a\xab\x35\x7d\x7e\xee\x20\xcc\x41\xf1\xcb\x54\x08\xf2\x9d\xd6\xc2\x8c\x88\xce\xc5\x05\xfc\x03\x75\xdc\x2c\x31\xd1\xe1\xf4\x0e\xb2\x37\xde\x59\xc4\x73\x68\x36\xd8\x7c\xd6\xb2\x70\x58\xa1\x53\xa9\x31\xfc\x70\x2b\x5f\xb3\x16\xbf\x78\x39\x3d\x22\x49\x67\x8b\x95\x16\x19\xb3\x65\xca\x57\x4e\x1e\x87\x82\x75\x7b\x10\x13\x38\xf7\x26\x24\xd8\x96\xea\x6d\x2d\x73\x4e\xdf\x71\x21\xf8\xfe\xf9\x53\x77\x6d\x7f\x9d\x6a\xe6\x1c\x60\xb6\xfe\xbc\x78\x01\x3b\xc2\x68\x33\x9d\x5c\xf3\xbe\x6b\x8d\x07\x6b\xcf\x01\xfc\x42\xed\x73\xea\xa5\xc9\xf0\xda\xbf\x39\xda\x30\x15\x1e\xf1\x24\x3f\xde\xc1\x5d\x38\x72\xae\x79\x8b\xd3\x9a\xc4\x1c\xba\xf7\x44\x11\x9d\xbf\x53\x24\x3c\xce\xf5\xb5\x0f\xe3\x7f\xfb\xea\x22\x74\x54\x9a\x3c\x47\x14\x1a\x87\xb7\x26\x41\xdf\xe1\x93\x43\xba\x38\xbc\x65\xb2\xdb\x21\x6b\xa7\xb9\xb5\x19\x13\xf9\xc7\x69\x52\x45\x43\x92\xf7\xf5\x3d\x6e\xf9\xbd\x7b\xe9\xca\x98\xd8\x3e\x78\x56\x29\x22\xbf\x90\xdd\x53\xc1\xd9\x16\xd9\x91\xf7\xc3\x45\x46\xc7\x5f\x90\x3f\xed\xcd\xd8\xe5\x2e\x88\xfe\x9c\x25\xc7\x63\x3b\x25\xb5\xd7\x21\x32\x58\x03\xbd\x4e\x54\x4e\x2a\xea\xdd\x93\xea\x43\xe5\x4d\xc9\xb2\x38\xf7\xe8\x03\xe3\x56\x56\x5e\x96\xaa\xa4\x27\x8a\xad\xa3\x3a\xaf\xdc\xc2\x5c\xf6\x4d\x06\x23\x92\xec\xfe\x92\xd1\xfa\x64\x5c\xbf\xdf\x09\x7e\xd7\xe1\x16\x5a\x94\x4a\xf0\x87\xe8\x8c\x78\xfd\x4e\xd4\x57\x87\xe2\x47\x02\x50\x28\x83\xd0\xe4\x1f\xf3\x6c\xd5\x00\xd9\xfc\x0c\x23\xf9\x93\x49\xf9\xad\x8f\x48\x8d\x7e\xe4\xe7\xb9\x98\x34\x84\xf1\xe1\xd7\x5c\x53\x6c\x88\xe1\x02\x93\xff\x45\xa5\x50\x0c\x23\x8c\xf7\xe6\x3a\x64\x4c\x9a\x1c\x4f\x04\x85\xe4\xce\x41\x4d\x5a\xa3\xca\x02\x2d\x2d\xf8\x2e\xa2\x1a\x7a\xd4\x41\x8e\xc2\xf2\xa1\xce\x5b\x3c\xf7\x1b\x54\x1b\x14\x99\x76\x3b\x35\xd2\x26\xb1\x17\x02\x99\xea\x1e\x0c\x93\xee\xf1\x20\x86\x55\xfd\xfc\x1b\xe7\xdd\x29\x38\x7a\x01\xff\xd7\xbf\x34\xb5\xd7\x16\xf6\xdf\x34\xff\xa6\xb3\x85\xe3\xe0\xf3\xe5\xc8\xc6\xb3\x1a\x75\x4a\xe8\x00\x76\xf8\x58\x47\xba\x5c\xd6\xad\x4a\xd8\x3d\xc5\x7d\x42\x5d\x6a\x1e\xae\x72\x5d\x71\x76\xec\x28\xb9\x63\xaa\xfd\x62\xa1\xb1\x23\x94\x49\xfb\x0c\x68\x35\x5b\x91\x4e\xe2\xe3\x09\x73\xae\x3f\xb6\xc6\x5f\xd4\x6c\xa5\x2b\xa0\xea\x99\x4d\x2a\x7d\x07\xd9\x7f\xf7\x07\x9d\x46\x79\x4d\x1a\x9d\xfc\x46\xea\xad\x05\x38\x6c\x7a\x5e\x2c\x52\xf8\x86\x2d\xcc\x65\x3c\xc7\x98\xb2\xb1\xa9\x1e\x93\xb5\x0c\xf1\x62\x9b\x7a\x77\x59\xe4\xe6\xe3\xb3\xe3\x5c\x18\x20\xaf\x03\x04\x39\x5d\x71\x71\x55\xf0\x64\x16\x93\x2d\x27\xca\x40\x3c\xe4\x93\xa6\xef\xe3\xa7\x43\xe4\x95\xcf\x73\x5a\x81\x18\xa7\xce\x5e\x3f\xd9\x1e\x08\xd4\xeb\x64\x1a\x1f\xeb\xe8\xb5\xdb\xbf\xfc\xc1\x17\x1f\x1c\xd5\x0a\x27\xf2\xd3\x40\x2a\xd1\x37\xaa\x16\x9a\x7b\xd1\x37\x29\xc3\x93\x65\xff\x28\xe6\x35\x86\xe4\xeb\x53\xc6\xfc\xee\x88\x35\x30\xeb\x48\xa8\xfa\xfb\xdc\xfa\x51\x1f\x23\x38\xe0\xda\x38\xe7\x1c\x89\xa0\xbf\x01\x76\xb2\x74\xdf\xdc\x7e\xaf\xba\x10\xfc\x94\x91\xbb\x4d\x0b\x34\x23\x3a\x9c\x85\x65\x78\xa2\xee\x5e\x75\x5d\x7e\x91\xda\xff\x94\xfa\x69\xfa\x18\x54\xef\x24\x65\x5d\x7c\xc6\x07\x59\xc5\x1c\x5a\x6a\x5c\x09\x22\xaa\xd8\xd7\xf5\xf4\x91\x94\x18\x0d\x1d\xb7\x43\x5f\xad\x3c\x7a\xb9\xfc\x56\x8a\x61\x6a\xca\x6a\x21\x69\x62\x9c\x52\xe9\x2a\xf6\xd6\xfd\x52\xf8\xfa\xad\xe2\x9a\x7a\x48\xda\x5b\x1b\x60\xba\x4c\xf7\x69\x76\x99\xf8\x2b\xa9\x1f\x19\xc0\x67\x05\x48\x27\xf6\xce\x0b\x5d\x9e\x68\x7e\x22\x89\x99\x05\x2a\xce\xd6\x9f\x88\xf2\x47\x97\xfb\x34\xa9\x13\x58\xfa\x54\xe8\x20\xb8\x1e\x23\xde\x8b\x57\x38\xac\x2a\x4f\x63\x2f\x98\xa9\xb4\x6f\xc9\x6e\xa7\x1d\x35\x2d\x64\xce\xca\x17\xa5\xcd\x91\x9a\xe6\x77\x8b\x96\x51\x90\x91\x3a\xe7\x69\xaa\x52\xd7\x92\xc4\xbe\xe5\x09\x25\x9f\x17\x70\x35\xc7\x15\x17\xdb\xcb\xb0\xdf\xfc\xe9\x92\x05\x17\x36\x12\x2e\x4b\xcd\xbf\xb9\x2a\xcd\x6f\x6f\xaf\xde\xbc\xaa\xd3\x7a\xba\xb1\xbd\x1a\x37\xb6\xc9\xc3\x17\x29\xc9\x95\x2b\xa9\x28\x39\x39\x1c\x60\x9b\x09\x8a\xf6\xff\x1a\xa2\xa6\xee\x35\x70\xa5\xf6\xd9\xe8\x9a\x02\xcd\x85\xe2\x16\xa1\xe9\x6c\x7c\xfd\xf7\x9c\xf9\x36\x7b\x47\xdc\xf5\xa6\x3c\x8a\x84\x5d\x26\x44\xd6\x62\xc4\x98\x03\xb2\x4c\x0f\x57\x9c\x72\x4e\xeb\x77\x66\x0a\x27\x23\x71\xd7\x9f\xf6\xd1\xd1\xdc\x23\xc1\xea\x77\xdf\xfa\x21\xf2\xfb\xf7\x3e\x1e\xec\xef\xf9\x98\xd8\xd5\x01\x3e\xfc\x09\x37\x5c\xa9\x66\xda\xdf\x8f\x1c\x92\x05\xca\x3b\x81\x12\x99\xb2\xee\x9c\x88\xfd\x06\xe4\x60\xf1\xd7\x2a\x23\xa1\xcc\x17\xd8\xa5\x22\x42\xc1\xd3\xa4\x01\xc1\xa4\xf6\xb4\xdb\x4b\xd8\x83\xab\x85\x06\xb0\xb9\x61\x34\xa5\x99\xa4\xa4\xb5\x27\x21\x99\xe7\xba\x18\xec\xe9\xe1\x44\x6a\xc3\xa7\x8e\x4a\x65\x4b\x67\x45\xa9\x75\x0e\x54\xc9\xa2\xb9\xc1\x16\xe2\x4c\x9c\xdf\x70\x26\x69\x8b\x02\x5b\x90\xbd\xb1\x4d\xab\xbe\xab\x5a\x67\xe7\xd3\x56\x18\x9e\x58\x1c\xd3\x74\xe2\xcb\xc1\xb1\x4d\x20\xf6\xa4\xf9\xba\xb2\x21\xd0\x34\x21\x84\xbd\x65\x87\x8d\x5f\xea\xab\xca\xa7\x03\xf1\x57\xb8\x47\xd3\xd2\xe4\x6e\xa3\x0a\x28\xac\x18\x85\xf4\x3a\xd8\x96\xd0\x83\x12\x1f\x41\x03\xdc\x72\x3e\x2d\x71\xb5\xbd\xf0\x42\x11\x04\x28\xbf\x8a\x31\x3c\xea\xc5\xf2\xe8\xf1\x30\xaa\xa6\x25\x63\xe6\xf5\x9d\xa5\xf3\x30\x92\x73\x84\x90\x1e\xf6\x57\xf3\xdc\xbd\x13\x91\x2d\x93\x1b\xff\x9b\xaf\xd8\xba\x0e\xc4\x1d\x91\x6a\x52\x71\x34\x86\x07\x2f\xc3\x9d\x0e\x17\x45\xa5\x59\x8e\xe4\x5c\x94\xbf\xee\xe1\xc6\xb2\xcd\x62\x59\x72\xa3\xe2\xe9\x1f\x34\x2d\xb9\x8b\x56\xb7\x28\xe3\x66\x24\x16\xcc\xb5\xa2\x9a\x2f\x84\x40\xb9\xe3\xac\xb5\x75\xb6\xf6\x40\x0c\xec\x74\xad\x88\x2a\x73\x15\x73\x0f\x6e\x29\x8f\x79\xce\xbf\x14\xaf\x32\x58\xcc\x4e\xd4\xcf\x6d\x79\x5c\xf5\xa4\x34\xc8\xcc\xb5\x72\xa4\x25\xd1\x36\xa7\x26\xee\x68\xd9\x62\x95\x16\x6c\xab\x3a\xee\x6b\xd1\x44\xda\x64\x66\xda\x08\x32\x76\xa8\x5e\xe4\x32\xbb\x41\xab\x73\x2d\x3a\x1c\x3b\xd7\xeb\xc8\x41\xf0\x62\x1a\x9d\x14\x0c\x0d\x4b\x4c\xb0\xb0\xac\x94\x46\x0d\x41\xcb\x61\x1d\xcc\xfc\x98\xe0\x7f\xa2\x42\x7c\x7b\x92\x31\xcf\x27\xab\x64\x34\x90\xb6\xf9\x28\x08\x8b\xa9\x82\x49\xdf\x27\xa0\x88\x58\x47\x21\x59\xa4\x67\x8d\x33\xd9\x3b\xb1\xf6\x98\x91\xec\x2a\x44\xbf\x4d\x3b\xf5\x36\xe6\x9f\xa6\xac\x9b\x2d\x82\x25\x5d\xd8\x57\x30\x24\x1f\x03\xfb\x66\x35\x02\x6f\x50\x50\xd2\xd1\xff\x73\xe5\xa2\x32\xc9\x04\x94\xe9\x48\x44\xab\x93\x0b\x50\xbc\x27\x0f\x3f\x7c\x49\xfb\xaa\x4e\xa7\x34\xba\xb7\x5e\x2e\xc6\xa9\x4d\x49\x4c\x7c\x62\xef\xe1\x4e\x16\x93\x59\xe6\x11\x9f\x4a\xa6\x61\x4e\xa3\x2c\x65\xd4\x54\xfb\x0c\x12\x89\x8b\x9f\x92\x79\xac\x7d\xac\x23\xcd\x67\xe9\x7b\xc5\x4e\x62\x40\x04\x54\x65\x81\x79\xb8\x09\x93\x3f\x84\xda\xf2\x08\x23\x64\x47\x1b\x74\xc9\x9e\x1f\xe7\xd0\xef\x6e\xf9\x65\x75\x71\x87\x6c\x5d\xd6\x77\x35\x94\x9d\x89\x5d\x60\x09\x93\xab\xc9\x28\x6b\x0d\x16\x19\xd7\xc7\x2e\xcb\x1e\x73\xfa\x7d\x0c\xcb\x15\x69\xc1\xd6\x45\xfc\x3b\x22\x4d\xaf\xd2\xa0\x5f\x35\x71\x1e\xbd\xbb\xe0\xfc\x04\x27\xf9\xae\x8d\x61\x91\x1b\x67\xd3\x67\x63\xd2\xf0\xd0\x98\x40\x66\x8b\x84\xa5\x0e\xc7\x86\x48\xf6\x4c\x3f\xcc\xeb\x9e\xcd\x33\x73\xa9\xbf\xa6\xac\xe9\xfa\xd6\xba\x89\x16\x15\x83\x01\x17\xe9\x11\x89\x7b\x7a\x9a\x30\xa4\xf9\xf0\x51\xe5\x8f\xa3\x0c\xce\x72\x47\x1a\x9d\xfb\x50\x61\x8e\x51\xe2\x96\xb6\x1a\x77\x8d\xd6\x58\x6e\xe5\x40\x63\x2e\x2c\xeb\xcd\x71\x87\xb6\x0d\xfd\xa2\x54\xa1\x53\x8b\xfc\xfc\x10\xf8\xe8\xef\x0c\xce\xd3\x9f\xa7\x4f\xe1\xec\xd0\xee\xc2\x7b\x29\x4c\x62\xaa\x82\xb3\x03\x8e\x97\xc3\x3c\x96\x6e\x46\x45\xd9\xb4\x2f\x8c\x66\xb1\x5d\xe7\x97\xe9\x6a\x23\x5a\xd9\xf8\x3d\x6d\x7d\xae\xba\x22\x1f\x5e\x0b\x6c\x11\x2e\x6d\x8e\xf8\xed\xf8\x6b\xfa\x87\xbf\x86\x70\xaa\xaf\xa7\x3f\xbf\x04\xc7\xe9\x88\x97\x77\x83\xe2\x1e\x65\xa5\x59\x92\x98\x36\x47\x14\xcf\xe4\x20\x97\xea\x74\xf8\x66\x63\xd4\x37\x6d\x79\xf4\x6d\x27\x26\x4c\x34\x8c\x04\x49\x56\xb8\xee\x89\x68\xed\x40\x4b\x6c\x27\x5c\x0b\xa2\xfd\x4b\xb7\x4c\xf1\x64\x34\xc6\xc9\xb7\x09\x23\x87\x31\xa6\xc9\x55\xef\xa9\xdc\xd8\x06\xbd\x16\x3b\x5c\xdb\x62\x85\x6b\x3b\xe1\x40\x18\x37\x06\xcd\xb7\x60\x4e\x71\xb1\x5e\xc0\xb6\xef\x14\x95\x34\x76\x9e\x4a\x54\xfd\x0e\x90\x91\x3b\xdb\xcf\x09\x2d\xde\x63\xc7\x77\x18\xbb\x99\x43\x8b\x26\x67\xe6\x99\xba\xc3\x0d\xe9\x56\x33\x1d\x91\x82\xb4\x0c\x08\x53\x34\xef\xde\xbf\xfe\xfb\xd5\xed\x2b\xdb\x8a\xda\x90\x1d\xb9\xa3\x1d\x55\x0f\x86\x1b\xbb\xfe\xae\xa3\x72\xa3\xb7\xb9\x86\x17\x81\x0d\xd2\xfb\xa4\x11\xb6\xee\x46\x87\x86\xd4\xa2\xd3\xb3\xac\xde\x84\x75\x7c\xcf\xd2\x9b\x3b\xdd\x10\x86\xfe\x89\xe0\x4a\x1e\x70\x0b\x0c\x94\x17\xc1\x77\x8c\x09\x2a\x83\x26\x95\xd0\x33\xbd\xa4\x3d\x9b\xcc\x1e\x2b\xcb\x2e\xb3\x75\x62\xd0\xe2\xa8\x37\x5a\x6e\x12\xa0\x12\x76\xe8\xe3\x94\xec\x55\x93\x76\x7e\x68\xb4\xdc\xb5\x80\x5f\x59\x10\xa6\x41\x67\xae\xaf\x33\x04\xb0\xab\xd0\xf8\x34\xd7\x27\xba\x54\x9c\x6f\x34\xb5\xc2\x61\xcb\xc5\x06\xa5\x76\x38\x0a\x16\x5a\x91\xaf\xd8\x83\x4b\x8a\x0c\x9a\x72\xcd\xb4\x15\x0d\x39\x67\xd8\x92\x16\x81\xac\x09\x8d\xad\xcd\x52\x7b\x8a\xfe\xd0\xe4\xe1\x0c\x03\x76\x39\x66\xa1\x05\x16\xae\xa4\xe9\xdb\x95\x88\xf3\x6c\x25\x95\xb0\x45\x81\xdd\x43\x80\x1a\x86\xf7\xb2\x0c\xb3\x86\x32\x07\x32\x70\x1d\x64\x80\x15\x46\xda\xee\x1e\xca\x99\xb5\x74\xb2\xcf\xcd\xb6\x39\x37\x3e\x40\x4d\xa3\xaf\x30\xce\x77\x82\xb6\x78\x3a\xbe\x0e\xe2\xba\xac\x38\xea\x5a\x3f\xdb\x41\xcc\x68\x05\xc9\xd3\xe0\xa2\xb4\x45\xa9\x40\x71\x9c\xc9\x4d\xd7\x95\x01\x77\x1e\xaa\x8d\x2f\x1a\xe4\x36\x06\xcd\x5a\xfa\xe3\x0a\x22\x31\x4a\x99\xdc\xda\x48\x27\x60\xdc\xfa\xf9\x16\xb3\xe6\x68\x36\x23\x14\x75\xfa\x24\x37\x50\xf7\x13\xc7\x6a\xe5\xee\x08\x27\x64\xc6\x59\xe7\xab\xaa\x6a\x9d\x6e\x89\x46\xca\xa1\x25\xd3\x0e\x98\xa6\x63\xf4\x24\xce\xc2\x68\x31\x31\xf4\xc0\xdb\x14\xfa\xd8\x68\xe2\x23\xdd\x87\xa3\xce\x83\xbb\xe4\x72\x4f\xee\x20\x9d\xd8\xfa\x05\x65\xfb\x97\x85\xd0\xd3\x76\x3e\x58\x17\x72\x08\x29\x16\xa3\xcd\x60\x10\x1a\xc2\x8c\xe6\x8f\xfc\xe6\xdb\xc2\xd2\xa3\x86\x2d\x62\x90\xb6\x89\xf9\xc1\xaf\x6c\xc5\xa3\xdf\x0d\x33\xd1\x78\xd2\xab\x61\x56\x46\x9b\x61\xa6\x92\x77\x49\x2c\x33\x32\xbc\x73\xdc\xf2\xd8\x43\xbf\x96\xd1\xaf\xcb\xca\x9f\x34\xc5\x58\x8e\x30\x1e\xd5\x1c\x33\x58\x50\xb6\xb3\x11\xe5\xe0\xc4\x41\xa1\x93\x2c\x8d\x43\x2e\xb6\x8e\xd9\x2f\xce\xe0\xaf\xd5\x26\xb2\xcb\xd1\x08\x61\xf2\x8b\x3d\xc9\xe7\x5a\xf5\x71\x5c\xc0\xda\x3c\x8b\x66\x68\x82\xf9\xf6\xaa\x8c\x2f\x87\x4c\x57\x2a\xfc\x23\xf3\x51\xd5\x78\x29\xbb\x4a\x37\x3e\x65\xa1\xe5\xca\x75\xda\x01\xb0\x74\x9b\x6b\x56\xc6\x4e\xa2\x7d\x67\x21\xe6\xa4\x6b\xb6\xf9\xe5\x22\xd8\x92\xd5\x5c\x7a\x3d\x85\xfe\xa8\xd0\x72\x59\xab\x9d\x0c\x6d\x4f\xc4\xc8\xff\x6d\x68\x01\x06\xf9\xfe\x22\x78\x87\xcc\x0e\x84\xfb\x3f\x7d\xfc\xaf\x44\x26\x19\xf1\xab\x63\x35\x36\x10\xf8\x18\x6e\x9d\xc5\x62\xc0\xef\x25\xfd\xb8\x09\x8c\x36\xf0\x35\x53\x28\x18\xe9\x8e\x8f\xfa\xa5\xb6\x30\x4e\xd3\x79\xd7\x29\x58\xb4\xe2\x41\xfc\xc5\x4f\xf9\xe5\x2f\xf2\x02\xfe\xe1\xbc\x25\xe7\xeb\xba\x84\xac\xad\x53\xb7\xb0\x23\x6a\xe3\xfd\xdf\x41\x60\xf7\x4c\x96\x23\x73\xa3\x3e\x9e\xf5\xb7\xe2\x18\x5c\xde\xb4\x7f\x7c\x8c\xea\x12\x7e\x1a\x3a\x86\x59\x87\x4b\xad\xa7\xa5\xde\xb9\x3e\x3e\x64\x53\x8c\xec\xb8\x38\xd1\xe3\xeb\x1d\x41\xfb\xe7\x1f\xd2\xd5\x3d\xf2\xb2\xd7\x90\xcf\xcf\xaa\x3c\xe6\x27\xf5\x77\x8f\x76\x77\x43\x3e\x87\x98\x44\x71\x87\x27\x24\x2c\x33\x9e\xc9\xf1\x69\x16\x2d\x70\x22\xf1\x45\x4d\x07\xbe\x73\xda\x6d\x07\x7e\x1b\xdb\x5d\x44\x6c\xcf\x0d\x10\x5d\x0e\x71\xc5\x7b\xa6\xe3\x9e\x4e\x72\xb7\x4f\x8e\x0c\xa6\x64\xf3\x19\x69\x55\xce\x35\x0a\x1d\x91\xce\xc3\x23\x01\xb5\x26\xc7\x61\xf3\xf9\xc9\x83\x4e\xbe\xed\x79\x7c\xc2\xe9\x2c\x1c\x78\x64\xb3\xc5\x7b\x4a\xd4\x65\x0e\x76\x96\x3c\x4d\xee\xea\x0c\x77\x7c\x9e\xe0\x18\xbb\xec\x55\x98\x31\x12\xc6\x87\x2d\x58\x02\xb7\x69\x30\x9b\x36\x24\xc6\x00\xea\xc8\x2c\xc7\x99\x4b\xb0\x6b\xbf\xe5\x87\x31\xdf\xba\x6c\x3c\x74\xb4\x9a\x09\x3e\x5f\xc7\x29\xec\x2d\x14\x91\x85\x1b\xcc\xf0\x5a\x7c\x7c\xc6\x23\x11\xf8\x97\x76\xaf\xcc\xa2\xec\x60\x62\x0f\xd8\xca\x03\x36\xb2\xa6\x14\x31\x83\x65\xce\x34\x80\x13\xf5\xb0\x97\x61\xa2\xc4\x4a\xd7\x6e\x94\xe4\x1a\xc9\xdf\x29\xc3\x7f\x76\x83\xae\x9f\x92\xf4\xe9\x95\x8e\x93\xf6\xf9\x4f\xa7\xf7\xe7\x0e\x47\x7d\x52\x33\x9b\x2d\x75\x1c\xca\x0c\x5d\x21\x3c\xc9\x49\x75\x09\x2b\xda\xf0\x4d\xc2\x20\x45\x2b\x6f\x3a\x83\x25\x4c\x7e\x9b\xe4\x3f\x16\x03\xf3\xb0\xcc\xfa\xcc\x06\x1e\x48\xda\x78\x36\xa9\xf9\x37\xfa\xcc\x49\xa5\xef\x2d\xfb\xda\x73\x7a\x58\xf9\xca\x1d\xb8\xd9\xa1\x66\x36\xe3\x5a\x24\x48\x4f\x8a\xf1\xbd\xf2\xff\xac\x06\x96\xb1\x83\xb1\x46\x41\x12\x0e\x86\x1c\x7d\xd9\x39\xa8\xb9\x59\xdb\xef\x67\xaf\x32\x2a\xbe\xa7\x13\xf0\x64\xf6\x8c\x99\xa9\xbc\x71\x77\x6c\xc2\x27\x6b\x02\x0f\x55\x86\xba\x03\xaf\x97\xe7\xeb\xcb\x39\x60\xeb\xab\x18\xbe\x4d\xdd\xb0\xe3\x28\xf7\xbd\x8d\xfb\xf6\xe4\x3f\x01\x00\x00\xff\xff\xac\x90\x9d\x2a\xee\x4b\x00\x00" func migrationcontractstagingCdcBytes() ([]byte, error) { @@ -180,6 +201,7 @@ func AssetNames() []string { // _bindata is a table, holding each asset generator, mapped to its name. var _bindata = map[string]func() (*asset, error){ + "DependencyAudit.cdc": dependencyauditCdc, "MigrationContractStaging.cdc": migrationcontractstagingCdc, } @@ -229,6 +251,7 @@ type bintree struct { } var _bintree = &bintree{nil, map[string]*bintree{ + "DependencyAudit.cdc": {dependencyauditCdc, map[string]*bintree{}}, "MigrationContractStaging.cdc": {migrationcontractstagingCdc, map[string]*bintree{}}, }} diff --git a/lib/go/templates/internal/assets/assets.go b/lib/go/templates/internal/assets/assets.go index 05aa235..ffa68ae 100644 --- a/lib/go/templates/internal/assets/assets.go +++ b/lib/go/templates/internal/assets/assets.go @@ -24,6 +24,8 @@ // transactions/coordinator/set_block_update_boundary.cdc (415B) // transactions/delegatee/execute_all_delegated_updates.cdc (687B) // transactions/delegatee/remove_delegated_updaters.cdc (567B) +// transactions/dependency-audit/admin/set_unstaged_cause_panic.cdc (330B) +// transactions/dependency-audit/admin/test_check_dependencies.cdc (440B) // transactions/host/publish_host_capability.cdc (2.303kB) // transactions/migration-contract-staging/admin/commit_migration_results.cdc (809B) // transactions/migration-contract-staging/admin/set_staging_cutoff.cdc (606B) @@ -588,6 +590,46 @@ func transactionsDelegateeRemove_delegated_updatersCdc() (*asset, error) { return a, nil } +var _transactionsDependencyAuditAdminSet_unstaged_cause_panicCdc = "\x1f\x8b\x08\x00\x00\x00\x00\x00\x00\xff\x7c\x8f\xc1\x4a\xc4\x40\x0c\x86\xef\xf3\x14\xb1\x07\x6d\x2f\x7d\x80\x22\x96\xaa\x77\x17\x64\x1f\x20\xce\xc4\x76\x60\x9b\x0c\x49\x8a\x88\xec\xbb\x4b\xad\x16\xf5\xb0\xb9\x25\xff\x9f\xfc\x5f\xf2\x5c\x44\x1d\xaa\x47\x2a\xc4\x89\x38\xbe\x0f\x4b\xca\x5e\x85\xe0\x8a\x6c\x18\x3d\x0b\xd7\x36\xc9\x72\x4a\x07\xe4\x1c\x3b\xb8\x17\x39\x35\xf0\x11\x00\x00\x8a\x52\x41\xa5\xda\xf2\xc8\xa4\x1d\x0c\x8b\x4f\x43\x8c\xb2\xb0\xff\x58\xd6\xda\xe4\xf6\x45\x54\xe5\xed\xf6\xfa\x5f\x58\x3b\xa4\x39\x73\x36\x57\x74\xd1\xbb\xfa\x55\x65\xee\xe0\xa2\xe9\xd9\x45\x71\xa4\x03\xfa\xd4\xf4\xad\x91\x7f\xb1\x3d\xf1\x91\xcd\x71\xa4\xb4\x2f\x67\xb2\xbf\xf4\xbf\x9a\x66\xe7\xeb\x7b\x28\xeb\xa4\xae\x1e\x56\x15\x58\x1c\x36\x58\x38\x96\x84\x4e\x0a\x2b\xd4\xf7\x1f\x37\x06\xb6\xe5\x5f\x55\xdb\x8d\x73\x38\x87\xcf\x00\x00\x00\xff\xff\xf6\xe7\x19\x2d\x4a\x01\x00\x00" + +func transactionsDependencyAuditAdminSet_unstaged_cause_panicCdcBytes() ([]byte, error) { + return bindataRead( + _transactionsDependencyAuditAdminSet_unstaged_cause_panicCdc, + "transactions/dependency-audit/admin/set_unstaged_cause_panic.cdc", + ) +} + +func transactionsDependencyAuditAdminSet_unstaged_cause_panicCdc() (*asset, error) { + bytes, err := transactionsDependencyAuditAdminSet_unstaged_cause_panicCdcBytes() + if err != nil { + return nil, err + } + + info := bindataFileInfo{name: "transactions/dependency-audit/admin/set_unstaged_cause_panic.cdc", size: 0, mode: os.FileMode(0), modTime: time.Unix(0, 0)} + a := &asset{bytes: bytes, info: info, digest: [32]uint8{0xce, 0x5a, 0xec, 0xee, 0x60, 0xe0, 0x8e, 0x75, 0xc8, 0xcc, 0xa3, 0x9f, 0xc0, 0x79, 0xa0, 0x82, 0x86, 0x36, 0xb5, 0x65, 0x77, 0xef, 0xe2, 0xad, 0x3f, 0x39, 0xf9, 0x73, 0xa9, 0x33, 0x6f, 0x22}} + return a, nil +} + +var _transactionsDependencyAuditAdminTest_check_dependenciesCdc = "\x1f\x8b\x08\x00\x00\x00\x00\x00\x00\xff\x7c\x8f\x41\x4b\xc3\x60\x0c\x86\xef\xfd\x15\xb1\x07\x6d\x61\xf4\x07\x14\xb1\x94\xed\x2c\xc2\x8e\xb2\xc3\xe7\xf7\xc5\x36\x68\x93\x92\xa4\x88\xca\xfe\xbb\xcc\x6e\x52\xc7\x58\x4e\x81\xf7\x4d\x78\x1e\x1a\x46\x51\x87\x7c\x83\x23\x72\x42\x8e\x9f\xed\x94\xc8\xf3\x2c\x73\x0d\x6c\x21\x3a\x09\x17\xe9\x94\x12\x5a\x9b\x92\xa2\x19\x5a\x0d\xcf\xc7\x7d\xb7\x82\x65\xe3\x31\x0c\xbf\xe9\xd6\x95\xb8\xdb\xad\x20\x4c\xde\x8b\xd2\x17\xea\xf2\xa8\x84\xef\x0c\x00\x60\x54\x1c\x83\x62\x61\xd4\x31\x6a\x0d\xed\xe4\x7d\x1b\xa3\x4c\xec\xa7\xca\x61\xe6\xb8\x7a\x11\x55\xf9\xb8\xbf\x3d\x03\xae\xda\x34\x10\x93\xb9\x06\x17\x7d\x28\x5e\x55\x86\x1a\xae\x96\xb6\x2e\x1a\x3a\x7c\x0a\xde\x97\x4d\xe5\x68\xbe\xee\x31\xbe\x6d\x16\x26\x97\xc5\x2f\xd8\xfe\x73\x2c\xff\x98\x9b\x06\xc6\xc0\x14\x8b\x7c\x2d\xd3\x7b\x02\x16\x87\x59\xe0\x3a\x1a\x1c\xf0\x8f\xc6\x77\x06\x36\x93\xde\xe4\xf3\xe7\x7d\xb6\xcf\x7e\x02\x00\x00\xff\xff\x32\x55\xf2\x44\xb8\x01\x00\x00" + +func transactionsDependencyAuditAdminTest_check_dependenciesCdcBytes() ([]byte, error) { + return bindataRead( + _transactionsDependencyAuditAdminTest_check_dependenciesCdc, + "transactions/dependency-audit/admin/test_check_dependencies.cdc", + ) +} + +func transactionsDependencyAuditAdminTest_check_dependenciesCdc() (*asset, error) { + bytes, err := transactionsDependencyAuditAdminTest_check_dependenciesCdcBytes() + if err != nil { + return nil, err + } + + info := bindataFileInfo{name: "transactions/dependency-audit/admin/test_check_dependencies.cdc", size: 0, mode: os.FileMode(0), modTime: time.Unix(0, 0)} + a := &asset{bytes: bytes, info: info, digest: [32]uint8{0x1e, 0x86, 0xa7, 0xd0, 0xea, 0x8d, 0xb3, 0xf0, 0xf9, 0xc8, 0xa2, 0xad, 0x64, 0x33, 0x95, 0xf, 0x14, 0x3b, 0x93, 0xeb, 0xcc, 0xbf, 0x44, 0x28, 0xdc, 0x19, 0x7c, 0xff, 0x38, 0xe5, 0xd7, 0x49}} + return a, nil +} + var _transactionsHostPublish_host_capabilityCdc = "\x1f\x8b\x08\x00\x00\x00\x00\x00\x00\xff\x9c\x55\xef\x6b\xe3\x46\x10\xfd\xae\xbf\x62\xe2\xc2\x55\x06\xd7\xfe\x6e\x2e\x77\x84\x94\xe3\x0a\xe5\x08\xa4\xfd\x5c\xc6\xab\xb1\x34\x64\xbd\xbb\xcc\x8e\xec\x98\x92\xff\xbd\xac\x7e\xd8\x92\x63\xa5\xc9\xe9\x8b\xb1\xbd\xf3\xde\xbc\x37\xf3\xb4\xbf\xa0\xb5\xfe\x70\x67\x8c\xaf\x9d\xfe\xc9\xee\x89\x5d\x99\x65\xbc\x0b\x5e\x14\x66\x8f\x8a\x25\x15\xf7\xde\xa9\xa0\xd1\xbf\x43\x81\x4a\x71\x96\x65\xab\xd5\x0a\xd2\xe1\x08\x5a\x11\x44\x2e\x1d\xc9\xaf\x11\xee\x6a\xad\x3a\x28\x40\x57\x00\x39\x83\x21\xd6\x36\x55\x01\x3b\x40\xf8\xee\xa3\x82\x50\xf4\xb5\x18\x5a\x40\xa8\x37\x96\x63\xc5\xae\xec\xff\xbb\xc7\x80\x1b\xb6\xac\x47\xd8\x7a\x69\xe1\x03\x19\xde\x32\x15\x0d\xad\x90\xe1\xc0\xe4\x74\x09\x7f\x55\x1c\xe1\xe0\x6b\x9b\x98\x70\x63\xa9\x39\x7e\x3a\x00\xea\x81\x9e\xc9\xd4\x4a\x80\xb2\x61\x15\x94\x23\x98\x4e\x0c\xd4\xad\x1a\xf0\x6e\x2c\x62\x43\x15\xda\xed\x32\x91\x65\x2a\xe8\x22\x1a\x65\xef\xf2\xae\xd7\x6f\x5e\xd6\x70\x57\x14\x42\x31\xce\xe1\xdf\x2c\x03\x00\x08\x42\x01\x85\xf2\x16\x64\x3d\x34\xe2\x74\x26\x3d\xab\x15\xfc\x4e\xc2\x7b\x82\x80\x5a\xc5\x46\xe2\xd0\xb4\x4f\x17\x26\x30\xc5\x05\x70\x41\x4e\x79\x7b\x4c\x2e\x8d\x05\x7a\x37\x70\xf0\x44\x62\x49\x01\x5b\xc0\x7b\x0c\x0f\xc2\x7b\x54\x7a\x40\xad\xe0\x16\x06\xdf\xf2\x53\x41\xff\x74\x44\x9c\x14\x5c\x1f\xfd\xdd\x09\xf6\x9f\xd9\xd2\x78\x67\x50\x3b\xcd\x4b\x6c\x2d\x59\xaa\x7f\x54\x61\x57\xe6\xf3\xf9\x88\x60\x7e\x33\x6a\xb0\xf2\x51\xa7\x5b\xfb\xff\x4e\x92\x4f\xe7\x1e\xce\xb3\x19\xf2\xcf\x6f\x46\xce\x3f\x92\xd6\x61\xb8\x60\xde\x41\xed\x0a\x12\xdb\x58\x9b\x74\xa4\xcf\xd4\x59\xef\xdf\xa9\x9c\xb7\x70\xd3\x09\x2d\x49\xcf\x18\x9f\x3f\x0d\xc6\xf7\x25\xbf\x6a\xfb\x7c\x69\x2a\x32\x4f\x79\xda\x84\xa1\x23\x1d\x5e\xed\x2c\xbb\xa7\x89\xd2\x6b\x05\xe9\x78\xc7\xf8\x9e\xaa\xf4\x7c\xfd\x0a\x01\x1d\x9b\x7c\xf6\x20\x7e\x63\x69\x07\xb6\x8d\xfa\x68\xfb\xce\xb2\x66\x67\x88\x97\x89\xbd\x82\x5b\xf8\x69\x43\xce\x63\xc1\x18\x49\x86\x32\x7a\xaf\x16\xb0\xa3\x18\xb1\xa4\x35\xcc\xfe\x70\x7b\xb4\x5c\x4c\xf4\x0a\x42\x2a\x4c\x7b\x2a\x66\xf3\x2b\xf3\xbe\x78\xe3\x1c\x04\x43\xe8\x93\x14\x84\xf6\xec\xeb\x68\x9b\xd7\xc2\x96\xcb\x5a\xa8\xe8\x35\x82\x49\x14\xd8\x70\x0c\xf7\xa0\x53\xad\xc7\x40\x39\xea\x1a\xae\xae\xe7\x32\xd1\x3e\xaa\x17\x2c\x5b\xc9\x70\x7b\x0b\x8e\xed\xf5\x15\x88\xb8\xa7\xd7\x71\xfc\xfc\xdb\x04\xb6\x11\x42\xa5\x1f\x74\x48\x24\x03\xef\xd6\x83\xf1\xcc\x17\xaf\xf0\xd4\xbf\xb3\xd9\x71\x6e\xaf\x6c\xc2\x74\x1a\xa6\xf1\xbf\xe4\x17\x91\x7f\x5f\x2c\x2e\x8b\xa6\x02\xf1\x21\xea\x05\x28\x4a\x49\xef\x1e\xde\x44\x18\x12\xea\x5b\x49\xf8\x88\x19\xaf\x22\xd1\x81\xbf\x95\x87\xcb\x0b\x73\x2a\x08\xdf\xd8\xa1\xb5\xc7\xfe\xae\x68\x56\xff\xb2\x56\x7d\xf3\x73\xbf\xfb\x5a\xa1\xc2\x81\xad\x85\xa8\x5e\xda\x8b\xb5\x15\x20\xd9\x85\xfb\xec\x36\xfe\x79\xd9\x61\x8f\xb7\xb8\xd3\x30\x5e\x45\x87\x3b\x9a\x32\xbe\xc1\xfa\xde\x56\x75\x9d\xfd\xc0\x1d\x3d\x08\x6d\xf9\xf9\xed\x97\xfd\x98\xe4\x74\x47\xae\xe1\x7c\x3c\x1b\xef\xf4\x4b\xf6\x92\xfd\x17\x00\x00\xff\xff\x61\x05\xe9\x2d\xff\x08\x00\x00" func transactionsHostPublish_host_capabilityCdcBytes() ([]byte, error) { @@ -1003,6 +1045,8 @@ var _bindata = map[string]func() (*asset, error){ "transactions/coordinator/set_block_update_boundary.cdc": transactionsCoordinatorSet_block_update_boundaryCdc, "transactions/delegatee/execute_all_delegated_updates.cdc": transactionsDelegateeExecute_all_delegated_updatesCdc, "transactions/delegatee/remove_delegated_updaters.cdc": transactionsDelegateeRemove_delegated_updatersCdc, + "transactions/dependency-audit/admin/set_unstaged_cause_panic.cdc": transactionsDependencyAuditAdminSet_unstaged_cause_panicCdc, + "transactions/dependency-audit/admin/test_check_dependencies.cdc": transactionsDependencyAuditAdminTest_check_dependenciesCdc, "transactions/host/publish_host_capability.cdc": transactionsHostPublish_host_capabilityCdc, "transactions/migration-contract-staging/admin/commit_migration_results.cdc": transactionsMigrationContractStagingAdminCommit_migration_resultsCdc, "transactions/migration-contract-staging/admin/set_staging_cutoff.cdc": transactionsMigrationContractStagingAdminSet_staging_cutoffCdc, @@ -1105,6 +1149,12 @@ var _bintree = &bintree{nil, map[string]*bintree{ "execute_all_delegated_updates.cdc": {transactionsDelegateeExecute_all_delegated_updatesCdc, map[string]*bintree{}}, "remove_delegated_updaters.cdc": {transactionsDelegateeRemove_delegated_updatersCdc, map[string]*bintree{}}, }}, + "dependency-audit": {nil, map[string]*bintree{ + "admin": {nil, map[string]*bintree{ + "set_unstaged_cause_panic.cdc": {transactionsDependencyAuditAdminSet_unstaged_cause_panicCdc, map[string]*bintree{}}, + "test_check_dependencies.cdc": {transactionsDependencyAuditAdminTest_check_dependenciesCdc, map[string]*bintree{}}, + }}, + }}, "host": {nil, map[string]*bintree{ "publish_host_capability.cdc": {transactionsHostPublish_host_capabilityCdc, map[string]*bintree{}}, }}, diff --git a/tests/dependency_audit_tests.cdc b/tests/dependency_audit_tests.cdc new file mode 100644 index 0000000..84352e1 --- /dev/null +++ b/tests/dependency_audit_tests.cdc @@ -0,0 +1,220 @@ +import Test +import BlockchainHelpers +import "DependencyAudit" + +// NOTE: This is an artifact of the implicit Test API - it's not clear how block height transitions between test cases +access(all) let blockHeightBoundaryDelay: UInt64 = 15 + +// Contract hosts as defined in flow.json +access(all) let adminAccount = Test.getAccount(0x0000000000000007) +access(all) let fooAccount = Test.getAccount(0x0000000000000008) +access(all) let aAccount = Test.getAccount(0x0000000000000009) +access(all) let bcAccount = Test.getAccount(0x0000000000000010) + +// Content of update contracts as hex strings +access(all) let aUpdateCode = "61636365737328616c6c2920636f6e747261637420696e746572666163652041207b0a202020200a2020202061636365737328616c6c29207265736f7572636520696e746572666163652049207b0a202020202020202061636365737328616c6c292066756e20666f6f28293a20537472696e670a202020202020202061636365737328616c6c292066756e2062617228293a20537472696e670a202020207d0a0a2020202061636365737328616c6c29207265736f757263652052203a2049207b0a202020202020202061636365737328616c6c292066756e20666f6f28293a20537472696e67207b0a20202020202020202020202072657475726e2022666f6f220a20202020202020207d0a202020202020202061636365737328616c6c292066756e2062617228293a20537472696e67207b0a20202020202020202020202072657475726e2022626172220a20202020202020207d0a202020207d0a7d" +access(all) let aUpdateCadence = String.fromUTF8(aUpdateCode.decodeHex()) ?? panic("Problem decoding aUpdateCode") + +access(all) fun setup() { + var err = Test.deployContract( + name: "MigrationContractStaging", + path: "../contracts/MigrationContractStaging.cdc", + arguments: [] + ) + Test.expect(err, Test.beNil()) + + err = Test.deployContract( + name: "Foo", + path: "../contracts/test/Foo.cdc", + arguments: [] + ) + Test.expect(err, Test.beNil()) + + err = Test.deployContract( + name: "A", + path: "../contracts/test/A.cdc", + arguments: [] + ) + Test.expect(err, Test.beNil()) + + err = Test.deployContract( + name: "B", + path: "../contracts/test/B.cdc", + arguments: [] + ) + Test.expect(err, Test.beNil()) + + err = Test.deployContract( + name: "C", + path: "../contracts/test/C.cdc", + arguments: [] + ) + Test.expect(err, Test.beNil()) + + let excludedAddresses: [Address] = [ + // exclude the admin account + 0x0000000000000007 + ] + err = Test.deployContract( + name: "DependencyAudit", + path: "../contracts/DependencyAudit.cdc", + arguments: [excludedAddresses] + ) + Test.expect(err, Test.beNil()) + + +} + + +access(all) fun testChekDependenciesWithEmptyList() { + let addresses: [Address] = [] + let names: [String] = [] + let authorizers: [Address] = [] + let commitResult = executeTransaction( + "../transactions/dependency-audit/admin/test_check_dependencies.cdc", + [addresses, names, authorizers], + adminAccount + ) + Test.expect(commitResult, Test.beSucceeded()) + + let events = Test.eventsOfType(Type()) + Test.assertEqual(0, events.length) +} + +access(all) fun testChekDependenciesWithExcludedEntries() { + let addresses: [Address] = [adminAccount.address] + let names: [String] = ["DependencyAudit"] + let authorizers: [Address] = [] + let commitResult = executeTransaction( + "../transactions/dependency-audit/admin/test_check_dependencies.cdc", + [addresses, names, authorizers], + adminAccount + ) + Test.expect(commitResult, Test.beSucceeded()) + + let events = Test.eventsOfType(Type()) + Test.assertEqual(0, events.length) +} + +access(all) fun testChekDependenciesWithUnstagedEntries() { + let addresses: [Address] = [fooAccount.address] + let names: [String] = ["Foo"] + let authorizers: [Address] = [] + let commitResult = executeTransaction( + "../transactions/dependency-audit/admin/test_check_dependencies.cdc", + [addresses, names, authorizers], + adminAccount + ) + Test.expect(commitResult, Test.beSucceeded()) + + let events = Test.eventsOfType(Type()) + Test.assertEqual(1, events.length) + + let evt = events[0] as! DependencyAudit.UnstagedDependencies + Test.assertEqual(1, evt.dependenciesAddresses.length) + Test.assertEqual(1, evt.dependenciesNames.length) + Test.assertEqual(fooAccount.address, evt.dependenciesAddresses[0]) + Test.assertEqual("Foo", evt.dependenciesNames[0]) +} + + +access(all) fun testChekDependenciesWithStagedEntries() { + var events = Test.eventsOfType(Type()) + Test.assertEqual(1, events.length) + + let addresses: [Address] = [aAccount.address] + let names: [String] = ["A"] + let authorizers: [Address] = [] + var commitResult = executeTransaction( + "../transactions/dependency-audit/admin/test_check_dependencies.cdc", + [addresses, names, authorizers], + adminAccount + ) + Test.expect(commitResult, Test.beSucceeded()) + + events = Test.eventsOfType(Type()) + Test.assertEqual(2, events.length) + let evt = events[1] as! DependencyAudit.UnstagedDependencies + Test.assertEqual(1, evt.dependenciesAddresses.length) + Test.assertEqual(1, evt.dependenciesNames.length) + Test.assertEqual(aAccount.address, evt.dependenciesAddresses[0]) + Test.assertEqual("A", evt.dependenciesNames[0]) + + let aStagingTxResult = executeTransaction( + "../transactions/migration-contract-staging/stage_contract.cdc", + ["A", aUpdateCadence], + aAccount + ) + Test.expect(aStagingTxResult, Test.beSucceeded()) + + events = Test.eventsOfType(Type()) + Test.assertEqual(2, events.length) + + commitResult = executeTransaction( + "../transactions/dependency-audit/admin/test_check_dependencies.cdc", + [addresses, names, authorizers], + adminAccount + ) + Test.expect(commitResult, Test.beSucceeded()) + + events = Test.eventsOfType(Type()) + Test.assertEqual(2, events.length) +} + + +access(all) fun testChekDependenciesWithMixedEntries() { + var events = Test.eventsOfType(Type()) + Test.assertEqual(2, events.length) + + let addresses: [Address] = [adminAccount.address, fooAccount.address, aAccount.address, bcAccount.address] + let names: [String] = ["DependencyAudit", "Foo", "A", "B"] + let authorizers: [Address] = [] + var commitResult = executeTransaction( + "../transactions/dependency-audit/admin/test_check_dependencies.cdc", + [addresses, names, authorizers], + adminAccount + ) + Test.expect(commitResult, Test.beSucceeded()) + + events = Test.eventsOfType(Type()) + Test.assertEqual(3, events.length) + + let evt = events[2] as! DependencyAudit.UnstagedDependencies + Test.assertEqual(2, evt.dependenciesAddresses.length) + Test.assertEqual(2, evt.dependenciesNames.length) + Test.assertEqual(fooAccount.address, evt.dependenciesAddresses[0]) + Test.assertEqual("Foo", evt.dependenciesNames[0]) + Test.assertEqual(bcAccount.address, evt.dependenciesAddresses[1]) + Test.assertEqual("B", evt.dependenciesNames[1]) +} + +access(all) fun testSetPanic() { + let shouldPanic: Bool = true + var commitResult = executeTransaction( + "../transactions/dependency-audit/admin/set_unstaged_cause_panic.cdc", + [shouldPanic], + adminAccount + ) + Test.expect(commitResult, Test.beSucceeded()) + + var events = Test.eventsOfType(Type()) + Test.assertEqual(1, events.length) + + let evt = events[0] as! DependencyAudit.PanicOnUnstagedDependenciesChanged + Test.assertEqual(true, evt.shouldPanic) +} + + +access(all) fun testChekDependenciesWithUnstagedEntriesPanics() { + let addresses: [Address] = [fooAccount.address] + let names: [String] = ["Foo"] + let authorizers: [Address] = [] + let commitResult = executeTransaction( + "../transactions/dependency-audit/admin/test_check_dependencies.cdc", + [addresses, names, authorizers], + adminAccount + ) + Test.expect(commitResult, Test.beFailed()) + // not sure how to test this: + // Test.expect(commitResult.error!.message, Test.contain("panic: Found unstaged dependencies: A.0x0000000000000008.Foo") ) +} diff --git a/transactions/dependency-audit/admin/set_unstaged_cause_panic.cdc b/transactions/dependency-audit/admin/set_unstaged_cause_panic.cdc new file mode 100644 index 0000000..ff4a452 --- /dev/null +++ b/transactions/dependency-audit/admin/set_unstaged_cause_panic.cdc @@ -0,0 +1,8 @@ +import "DependencyAudit" + +transaction(shouldPanic: Bool) { + prepare(signer: AuthAccount) { + signer.borrow<&DependencyAudit.Administrator>(from: DependencyAudit.AdministratorStoragePath)?.setPanicOnUnstagedDependencies(shouldPanic: shouldPanic) + ?? panic("Could not borrow DependencyAudit.Administrator from signer's storage!") + } +} diff --git a/transactions/dependency-audit/admin/test_check_dependencies.cdc b/transactions/dependency-audit/admin/test_check_dependencies.cdc new file mode 100644 index 0000000..83b3df3 --- /dev/null +++ b/transactions/dependency-audit/admin/test_check_dependencies.cdc @@ -0,0 +1,8 @@ +import "DependencyAudit" + +transaction(dependenciesAddresses: [Address], dependenciesNames: [String], authorizers: [Address]) { + prepare(signer: AuthAccount) { + signer.borrow<&DependencyAudit.Administrator>(from: DependencyAudit.AdministratorStoragePath)?.testCheckDependencies(dependenciesAddresses, dependenciesNames, authorizers) + ?? panic("Could not borrow DependencyAudit.Administrator from signer's storage!") + } +}