davsession

package
v0.11.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Nov 26, 2026 License: MIT Imports: 5 Imported by: 0 modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Overview

Package davsession scripts the write sessions that are recorded against a provider's servers and replayed in tests (docs/design/testing.md, DAV and Tasks recordings). tools/davsession runs a session against the provider through a recording transport; the replay test runs the same session against the scrubbed recording. Both run this code, so they send the same requests in the same order.

Index

Constants

View Source
const GoogleZone = "America/New_York"

GoogleZone is the zone the Google session's events are written in.

View Source
const MicrosoftZone = "America/New_York"

MicrosoftZone is the zone the Microsoft session's events are written in.

Variables

This section is empty.

Functions

func Google

func Google(ctx context.Context, s Session) error

Google is the Gmail write session: on the account's default calendar, a single event made, changed, deleted and restored; a daily series changed in each scope (This Event restored at once, as Ctrl+Z does); an all-day event made and deleted; then a contact made, changed, given a photo, deleted and restored. Everything it makes is deleted at the end, and a last pass finds nothing changed. Each write is followed by one pass, which sends it.

func Microsoft

func Microsoft(ctx context.Context, s Session) error

Microsoft is the Outlook.com write session over Microsoft Graph (plan 0010, Phase 3b), on the account's default calendar: a single event made, changed, deleted and restored; a daily series with an occurrence moved and the move undone, an occurrence deleted, every occurrence changed, the series moved to another time (Outlook drops its exceptions then, and they are written again) and split from its fourth; an all-day event made and deleted; then a contact made, changed, given a photo, deleted and restored. Everything it makes is deleted at the end, and a last pass finds nothing changed. Each write is followed by one pass, which sends it. Its events and its contact are named "FM replay".

Types

type Session

type Session struct {
	Calendar api.CalendarService
	People   api.PeopleService
	// Pass runs one sync pass of the account.
	Pass func(context.Context) error
	// Step, when set, hears each step's name before it runs.
	Step func(name string)
}

Session is what a script drives: an engine's calendar and people services over one account, and a sync pass of that account.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL