Ejemplo n.º 1
0
        public async Task get_known_data_assets_should_return_data_asset_info()
        {
            _consumerService.GetKnownDataAssetsAsync()
            .Returns(new[] { new DataAssetInfo(Keccak.Zero, "test", "test") });
            var result = await _rpc.ndm_getKnownDataAssets();

            await _consumerService.Received().GetKnownDataAssetsAsync();

            result.Data.Should().ContainSingle();
            var dataAsset = result.Data.Single();

            dataAsset.Id.Should().Be(Keccak.Zero);
            dataAsset.Name.Should().Be("test");
            dataAsset.Description.Should().Be("test");
        }