diff --git a/internal/fixtures/web/uint256_job.json b/internal/fixtures/web/uint256_job.json index 4f54ef0c7ff..421ab7fd1df 100644 --- a/internal/fixtures/web/uint256_job.json +++ b/internal/fixtures/web/uint256_job.json @@ -1,8 +1,6 @@ { "initiators": [{ "type": "web" }], "tasks": [ - { "type": "HttpGet", "url": "https://bitstamp.net/api/ticker/" }, - { "type": "JsonParse", "path": ["last"] }, { "type": "Multiply", "times": 100 }, { "type": "EthUint256" } ] diff --git a/internal/fixtures/web/uint256_string_times_job.json b/internal/fixtures/web/uint256_string_times_job.json deleted file mode 100644 index 0cd66bcdc49..00000000000 --- a/internal/fixtures/web/uint256_string_times_job.json +++ /dev/null @@ -1,9 +0,0 @@ -{ - "initiators": [{ "type": "web" }], - "tasks": [ - { "type": "HttpGet", "url": "https://bitstamp.net/api/ticker/" }, - { "type": "JsonParse", "path": ["last"] }, - { "type": "Multiply", "times": "100" }, - { "type": "EthUint256" } - ] -} diff --git a/web/integration_test.go b/web/integration_test.go index 71de87dd260..272e7fe10f3 100644 --- a/web/integration_test.go +++ b/web/integration_test.go @@ -329,42 +329,12 @@ func TestIntegration_WeiWatchers(t *testing.T) { } func TestIntegration_MultiplierUint256(t *testing.T) { - gock.EnableNetworking() - defer cltest.CloseGock(t) - app, cleanup := cltest.NewApplication() defer cleanup() app.Start() - gock.New("https://bitstamp.net"). - Get("/api/ticker"). - Reply(200). - JSON(`{"last": "10221.30"}`) - j := cltest.FixtureCreateJobViaWeb(t, app, "../internal/fixtures/web/uint256_job.json") - jr := cltest.CreateJobRunViaWeb(t, app, j) - jr = cltest.WaitForJobRunToComplete(t, app.Store, jr) - - val, err := jr.Result.Value() - assert.Nil(t, err) - assert.Equal(t, "0x00000000000000000000000000000000000000000000000000000000000f98b2", val) -} - -func TestIntegration_MultiplierUint256String(t *testing.T) { - gock.EnableNetworking() - defer cltest.CloseGock(t) - - app, cleanup := cltest.NewApplication() - defer cleanup() - app.Start() - - gock.New("https://bitstamp.net"). - Get("/api/ticker"). - Reply(200). - JSON(`{"last": "10221.30"}`) - - j := cltest.FixtureCreateJobViaWeb(t, app, "../internal/fixtures/web/uint256_string_times_job.json") - jr := cltest.CreateJobRunViaWeb(t, app, j) + jr := cltest.CreateJobRunViaWeb(t, app, j, `{"value":"10221.30"}`) jr = cltest.WaitForJobRunToComplete(t, app.Store, jr) val, err := jr.Result.Value()