test_value_move_to_precompiles()¶
Documentation for tests/amsterdam/eip2780_reduce_intrinsic_tx_gas/test_value_moving_transactions.py::test_value_move_to_precompiles@a9abd46e.
Generate fixtures for these test cases for Amsterdam with:
fill -v tests/amsterdam/eip2780_reduce_intrinsic_tx_gas/test_value_moving_transactions.py::test_value_move_to_precompiles --fork Amsterdam
Ensure value moving transactions to precompiles charge gas correctly.
Precompile recipients pay the same COLD_ACCOUNT_ACCESS at
intrinsic time as any other non-self target -- access lists do
not warm transaction-level accounts. A value transfer to a
precompile additionally pays the transfer-log and value-transfer
charges.
The top-frame NEW_ACCOUNT state charge keys solely on EIP-161
emptiness; a precompile address is not special-cased. The
pre_funded parameter exercises both pre-tx states:
not_funded: the precompile address is empty per EIP-161, so a value transfer creates it and paysNEW_ACCOUNT-- exactly like any other empty recipient.pre_funded: the precompile already holds a balance and is therefore alive, so noNEW_ACCOUNTcharge applies.
Source code in tests/amsterdam/eip2780_reduce_intrinsic_tx_gas/test_value_moving_transactions.py
307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359 360 361 362 363 364 365 366 367 368 369 370 371 372 373 374 375 376 377 378 379 380 381 382 383 384 385 386 387 388 389 390 391 392 393 394 395 396 397 398 399 400 401 402 403 404 405 406 407 408 409 410 411 412 413 414 415 416 417 418 419 420 421 422 423 424 425 | |
Parametrized Test Cases¶
This test generates 72 parametrized test cases across 1 fork.