Fixed tests.
Refactoring to new FieldScripting class.