Exemple #1
0
        public SkuServiceTest(
            StripeMockFixture stripeMockFixture,
            MockHttpClientFixture mockHttpClientFixture)
            : base(stripeMockFixture, mockHttpClientFixture)
        {
            this.service = new SkuService(this.StripeClient);

            this.createOptions = new SkuCreateOptions
            {
                Attributes = new Dictionary <string, string>
                {
                    { "attr1", "value1" },
                    { "attr2", "value2" },
                },
                Currency  = "usd",
                Inventory = new SkuInventoryOptions
                {
                    Quantity = 100,
                    Type     = "finite",
                },
                PackageDimensions = new SkuPackageDimensionsOptions
                {
                    Height = 100,
                    Length = 100,
                    Weight = 100,
                    Width  = 100,
                },
                Price   = 1234,
                Product = "prod_123",
            };

            this.updateOptions = new SkuUpdateOptions
            {
                Metadata = new Dictionary <string, string>
                {
                    { "key", "value" },
                },
            };

            this.listOptions = new SkuListOptions
            {
                Limit = 1,
            };
        }
        public SkuServiceTest()
        {
            this.service = new SkuService();

            this.createOptions = new SkuCreateOptions
            {
                Attributes = new Dictionary <string, string>
                {
                    { "attr1", "value1" },
                    { "attr2", "value2" },
                },
                Currency  = "usd",
                Inventory = new InventoryOptions
                {
                    Quantity = 100,
                    Type     = "finite",
                },
                PackageDimensions = new PackageDimensionOptions
                {
                    Height = 100,
                    Length = 100,
                    Weight = 100,
                    Width  = 100,
                },
                Price   = 1234,
                Product = "prod_123",
            };

            this.updateOptions = new SkuUpdateOptions
            {
                Metadata = new Dictionary <string, string>
                {
                    { "key", "value" },
                },
            };

            this.listOptions = new SkuListOptions
            {
                Limit = 1,
            };
        }