Example #1
0
		public void AddressDecoding() {
			Address a = new Address(testParams, "n4eA2nbYqErp7H6jebchxAN59DmNpksexv");
			Assert.Equal("fda79a24e50ff70ff42f7d89585da5bd19d9e5cc", Hex.Encode(a.getHash160()));

			Address b = new Address(prodParams, "17kzeh4N8g49GFvdDzSf8PjaPfyoD1MndL");
			Assert.Equal("4a22c3c4cbb31e4d03b15550636762bda0baf85a", Hex.Encode(b.getHash160()));
		}
Example #2
0
		public void stringification() {
			// Test a testnet address.
			Address a = new Address(testParams, Hex.Decode("fda79a24e50ff70ff42f7d89585da5bd19d9e5cc"));
			Assert.Equal("n4eA2nbYqErp7H6jebchxAN59DmNpksexv", a.ToString());

			Address b = new Address(prodParams, Hex.Decode("4a22c3c4cbb31e4d03b15550636762bda0baf85a"));
			Assert.Equal("17kzeh4N8g49GFvdDzSf8PjaPfyoD1MndL", b.ToString());
		}