_, err := accountService.GetBlockDeviceTemplateGroups()
					Expect(err).To(HaveOccurred())
				}
			})
		})
	})

	Context("#GetHardware", func() {
		BeforeEach(func() {
			fakeClient.FakeHttpClient.DoRawHttpRequestResponse, err = testhelpers.ReadJsonTestFixtures("services", "SoftLayer_Account_Service_getHardware.json")
			Expect(err).ToNot(HaveOccurred())
		})

		It("returns an array of datatypes.SoftLayer_Hardware", func() {
			hardwares, err := accountService.GetHardware()
			Expect(err).ToNot(HaveOccurred())
			Expect(hardwares).ToNot(BeNil())
			Expect(len(hardwares)).To(BeNumerically(">", 0))
		})

		Context("when HTTP client returns error codes 40x or 50x", func() {
			It("fails for error code 40x", func() {
				errorCodes := []int{400, 401, 499}
				for _, errorCode := range errorCodes {
					fakeClient.FakeHttpClient.DoRawHttpRequestInt = errorCode

					_, err := accountService.GetHardware()
					Expect(err).To(HaveOccurred())
				}
			})