The correct option is
A to give
The verbs that do not explain the tense of the sentence and do not agree with the subject are called non-finite verbs. Non-finite verbs are usually infinitives, gerunds and participles.
Option A - 'Of giving' is not grammatically correct. 'Of' is a preposition, which is used to show 'belonging' or 'direction'. Hence, option A is incorrect.
Option C - 'Give' is a verb in present tense. As the non-finite verbs do not explain the tense of the sentence, we can't use 'give' here. It is a finite verb. Hence, option C is incorrect.
Option D - 'Gives' is a finite verb, as it agrees with the subject and also explains the tense of the sentence. Hence, option D is incorrect.
Option B - 'To give' is an infinitive and is a non-finite verb as it doesn't explain the tense. Hence, we can use 'to give' here. Thus option B is the correct answer.
'She promised to give the test as soon as possible.'